Skip to content

GCLOUD_PROJECT environment variable missing from the Node 10 runtime #437

Closed
@peterpeterparker

Description

@peterpeterparker

[REQUIRED] Version info

node:
Node v10

[REQUIRED] Steps to reproduce

I have upgraded my functions from Node v8 to Node v10. Compilation as upload in the cloud are ok but I face an error at runtime, respectively GCLOUD_PROJECT is not found/set

Here the stack trace of the error I found in the Firebase console:

Error: process.env.GCLOUD_PROJECT is not set.
    at DocumentBuilder (/srv/functions/node_modules/firebase-functions/lib/providers/firestore.js:99:23)
    at cloudFunctionNewSignature (/srv/functions/node_modules/firebase-functions/lib/cloud-functions.js:102:13)
    at cloudFunction (/srv/functions/node_modules/firebase-functions/lib/cloud-functions.js:151:20)
    at Promise.resolve.then (/srv/node_modules/@google-cloud/functions-framework/build/src/invoker.js:330:28)
    at process._tickCallback (internal/process/next_tick.js:68:7)

When I downgrade back to Node v8, I do not face that error.

Were you able to successfully deploy your functions?

Yes

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions