Failed to load function definition from source

5,463 views
Skip to first unread message

Light Yagami

unread,
Feb 10, 2023, 10:03:24 AM2/10/23
to Firebase Google Group
When running firebase emulator , I randomly (70% of the time) encounter this issue:

```
!!  functions: Failed to load function definition from source: FirebaseError: User code failed to load. Cannot determine backend specification
```
Restarting the emulator a couple of time fixes the issue temporarily.

Any help would be appreciated 


Cole Rogers

unread,
Feb 10, 2023, 1:24:55 PM2/10/23
to Firebase Google Group
Do you mind posting the generated `firebase-debug.log` from a run with this error? It will help us figure out what problem is occurring under the hood. Thanks!

Light Yagami

unread,
Feb 22, 2023, 3:27:15 PM2/22/23
to Firebase Google Group
There's no `firebase-debug.log` generated for some reason

Clément Lizé

unread,
Feb 28, 2023, 11:56:39 AM2/28/23
to Firebase Google Group
Same problem here, it seems to be only related to a new function I created based on a firestore onWrite event. When I deploy without this new function, it works 100%. But whenever I include the commits related to it, it starts failing.

We have plenty of very similar functions that work fine in the repository, but somehow adding this one makes the deployment fail.
Surprisingly, setting the "--debug" flag to our CI seems to make the deployment work. I mean isn't this flag supposed to add verbose only??

We're on Node 16 and using firebase-function version ^3.23.0

Also these issues seem to be strongly related:
Reply all
Reply to author
Forward
0 new messages