This error appeared when running functions that had not been altered since they had last run successfully and, when moved to another project, ran without generating any error messages.
The error message appeared no matter which function was run and even persisted when I got to the stage of removing all but the simple function below from the project:
function foo() {
Logger.log('bar');
}
Usually that error message gives a line number but it didn’t in this case.
What could cause that?
The error was actually in a library that was referenced as a resource by the project. I initially thought I had ruled that out by commenting out the library function but not so.
Presumably the lack of a line number should have been a hint that the error was in an external resource. I’ll know in future.
I’m answering my own question in the hope that it will save someone wasting the amount of time I’ve just wasted trying to locate the source of the problem.