Related
Im following a tutorial online on using express and firebase together (never used firebase before, but have worked with some express). For some reason everything seems to work when I use firebase serve or firebase emulators:start , but when I try to do a firebase deploy, it wont work. It did work the first time when I just started the project, but not anymore.
I saw one other question regarding the same error (I think he/she was following the same tutorial), but it wasn't helpful.
Console Error Displayed:
Function failed on loading user code. This is likely due to a bug in the user code. Error message: Error: please examine your function logs to see the error cause: https://cloud.google.com/functions/docs/monitoring/logging#viewing_logs.
Functions deploy had errors with the following functions:
api
Error: Functions did not deploy properly.
I added the firebase logs below. Also my repo: https://github.com/Sarman5432/SocialMediaApp/tree/master/functions.
[debug] [2020-12-19T05:48:54.719Z] ----------------------------------------------------------------------
[debug] [2020-12-19T05:48:54.722Z] Command: C:\Program Files\nodejs\node.exe C:\Users\Sarman\AppData\Roaming\npm\node_modules\firebase-tools\lib\bin\firebase.js deploy
[debug] [2020-12-19T05:48:54.722Z] CLI Version: 9.0.1
[debug] [2020-12-19T05:48:54.722Z] Platform: win32
[debug] [2020-12-19T05:48:54.722Z] Node Version: v12.14.0
[debug] [2020-12-19T05:48:54.724Z] Time: Sat Dec 19 2020 00:48:54 GMT-0500 (Eastern Standard Time)
[debug] [2020-12-19T05:48:54.724Z] ----------------------------------------------------------------------
[debug] [2020-12-19T05:48:54.724Z]
[debug] [2020-12-19T05:48:54.734Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2020-12-19T05:48:54.734Z] > authorizing via signed-in user
[debug] [2020-12-19T05:48:54.734Z] [iam] checking project socialmedia-5f158 for permissions ["cloudfunctions.functions.create","cloudfunctions.functions.delete","cloudfunctions.functions.get","cloudfunctions.functions.list","cloudfunctions.functions.update","cloudfunctions.operations.get","firebase.projects.get","firebasehosting.sites.update"]
[debug] [2020-12-19T05:48:54.738Z] >>> HTTP REQUEST POST https://cloudresourcemanager.googleapis.com/v1/projects/socialmedia-5f158:testIamPermissions
{"permissions":["cloudfunctions.functions.create","cloudfunctions.functions.delete","cloudfunctions.functions.get","cloudfunctions.functions.list","cloudfunctions.functions.update","cloudfunctions.operations.get","firebase.projects.get","firebasehosting.sites.update"]}
[debug] [2020-12-19T05:48:55.060Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:48:54 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","server-timing":"gfet4t7; dur=160","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:48:55.064Z] >>> HTTP REQUEST POST https://iam.googleapis.com/v1/projects/socialmedia-5f158/serviceAccounts/socialmedia-5f158#appspot.gserviceaccount.com:testIamPermissions
{"permissions":["iam.serviceAccounts.actAs"]}
[debug] [2020-12-19T05:48:55.365Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:48:55 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:48:55.368Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects/socialmedia-5f158
[debug] [2020-12-19T05:48:55.641Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:48:55 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[warn] ! functions: package.json indicates an outdated version of firebase-functions.
Please upgrade using npm install --save firebase-functions#latest in your functions directory.
[info]
[info] === Deploying to 'socialmedia-5f158'...
[info]
[info] i deploying functions, hosting
[debug] [2020-12-19T05:48:58.992Z] > [functions] package.json contents: {
"name": "functions",
"description": "Cloud Functions for Firebase",
"scripts": {
"lint": "eslint .",
"serve": "firebase emulators:start --only functions",
"shell": "firebase functions:shell",
"start": "npm run shell",
"deploy": "firebase deploy --only functions",
"logs": "firebase functions:log"
},
"engines": {
"node": "12"
},
"main": "index.js",
"dependencies": {
"busboy": "^0.3.1",
"firebase-admin": "^9.2.0",
"firebase-functions": "^3.11.0"
},
"devDependencies": {
"eslint": "^5.12.0",
"eslint-plugin-promise": "^4.0.1",
"firebase-functions-test": "^0.2.0"
},
"private": true
}
[info] i functions: ensuring required API cloudfunctions.googleapis.com is enabled...
[info] i functions: ensuring required API cloudbuild.googleapis.com is enabled...
[debug] [2020-12-19T05:49:00.832Z] >>> HTTP REQUEST GET https://serviceusage.googleapis.com/v1/projects/socialmedia-5f158/services/cloudfunctions.googleapis.com
[debug] [2020-12-19T05:49:00.832Z] >>> HTTP REQUEST GET https://serviceusage.googleapis.com/v1/projects/socialmedia-5f158/services/runtimeconfig.googleapis.com
[debug] [2020-12-19T05:49:00.832Z] >>> HTTP REQUEST GET https://serviceusage.googleapis.com/v1/projects/socialmedia-5f158/services/cloudbuild.googleapis.com
[debug] [2020-12-19T05:49:01.274Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:01 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:01.330Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:01 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[info] + functions: required API cloudfunctions.googleapis.com is enabled
[debug] [2020-12-19T05:49:01.341Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:01 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[info] + functions: required API cloudbuild.googleapis.com is enabled
[debug] [2020-12-19T05:49:01.345Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects/socialmedia-5f158/adminSdkConfig
[debug] [2020-12-19T05:49:01.595Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:01 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:01.601Z] >>> HTTP REQUEST POST https://firebasehosting.googleapis.com/v1beta1/sites/socialmedia-5f158/versions
{"config":{"rewrites":[{"glob":"**","path":"/index.html"}]},"labels":{"deployment-tool":"cli-firebase"}}
[debug] [2020-12-19T05:49:02.410Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:02 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[info] i functions: preparing functions directory for uploading...
[debug] [2020-12-19T05:49:02.413Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/socialmedia-5f158/configs
[debug] [2020-12-19T05:49:02.918Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:02 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:02.920Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/socialmedia-5f158/configs/api/variables
[debug] [2020-12-19T05:49:03.261Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:03 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:03.264Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/socialmedia-5f158/configs/api/variables/meaurementid
[debug] [2020-12-19T05:49:03.265Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/socialmedia-5f158/configs/api/variables/messagingsenderid
[debug] [2020-12-19T05:49:03.265Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/socialmedia-5f158/configs/api/variables/appid
[debug] [2020-12-19T05:49:03.266Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/socialmedia-5f158/configs/api/variables/key
[debug] [2020-12-19T05:49:03.464Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:03 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:03.737Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:03 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:03.743Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:03 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:03.745Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:03 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[info] i functions: packaged functions (47.16 KB) for uploading
[debug] [2020-12-19T05:49:04.508Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/projects/socialmedia-5f158/locations/-/functions
[debug] [2020-12-19T05:49:04.983Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:04 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:04.988Z] >>> HTTP REQUEST POST https://cloudfunctions.googleapis.com/v1/projects/socialmedia-5f158/locations/us-central1/functions:generateUploadUrl
[debug] [2020-12-19T05:49:05.674Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:05 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:05.676Z] >>> HTTP REQUEST PUT https://storage.googleapis.com/gcf-upload-us-central1-962ccae0-e24e-4d88-b0a2-d16db2e20c76/5cf7c6db-376e-483f-8e0b-ff8032a6a9b2.zip?GoogleAccessId=service-98194542320#gcf-admin-robot.iam.gserviceaccount.com&Expires=1608358745&Signature=ZfN05IUBG8tORoQvu67AzWLhLV01cC2C2PKWNe2yNYnhASSn6moWJ6wBzNdHp7mjjP7N3iJraaeTC8Vn7FEXSJ3yi1Zn4QLzGExoi8aiWDH%2BH6AxHLSYqEzhGa6YeqJIxIgCJTg2PxjoQkirf8TwNl5Ugo4intWpfmTQx%2F1a%2BsIJ6y5Y%2Bhvi9tpAVWXGGzrs0BDrGTF1Q4VTIdh72VA3t880RuH5rea%2BtrukA97EIfj6LzKRnRahdGZPcQESJ02Zy4jiXhurO1ifYHKTeAl2ifYbWxGVZBUUqiAYQoS%2F4EMF2%2FwNvUU0PGI4MjRFgYiJzUHcXUB%2FBmUivelQ5il4fw%3D%3D
<request body omitted>
[debug] [2020-12-19T05:49:06.038Z] <<< HTTP RESPONSE 200 {"x-guploader-uploadid":"ABg5-UzFi8fOApFhGG39w-A4SDe0GEI1RNC22-bc1BFAJ_pyTixewDMTCF_vHTnd_0o5K_YJwSsEJxXyr-X2jmI3tbqGXyO1YA","etag":"\"144ab95f99b5aca6b19fa25003cc63f1\"","x-goog-generation":"1608356945967446","x-goog-metageneration":"1","x-goog-hash":"crc32c=X2x8dQ==, md5=FEq5X5m1rKaxn6JQA8xj8Q==","x-goog-stored-content-length":"48292","x-goog-stored-content-encoding":"identity","vary":"Origin","content-length":"0","date":"Sat, 19 Dec 2020 05:49:05 GMT","server":"UploadServer","content-type":"text/html; charset=UTF-8","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\""}
[info] + functions: functions folder uploaded successfully
[info] i hosting[socialmedia-5f158]: beginning deploy...
[info] i hosting[socialmedia-5f158]: found 1 files in public
[debug] [2020-12-19T05:49:06.065Z] > refreshing access token with scopes: []
[debug] [2020-12-19T05:49:06.065Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token
<request body omitted>
[debug] [2020-12-19T05:49:06.068Z] [hosting] hash cache [cHVibGlj] stored for 1 files
[debug] [2020-12-19T05:49:06.068Z] [hosting][hash queue][FINAL] {"max":3,"min":3,"avg":3,"active":0,"complete":1,"success":1,"errored":0,"retried":0,"total":1,"elapsed":7}
[debug] [2020-12-19T05:49:06.229Z] <<< HTTP RESPONSE 200 {"pragma":"no-cache","date":"Sat, 19 Dec 2020 05:49:06 GMT","cache-control":"no-cache, no-store, max-age=0, must-revalidate","expires":"Mon, 01 Jan 1990 00:00:00 GMT","content-type":"application/json; charset=utf-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","server":"scaffolding on HTTPServer2","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:06.243Z] >>> [apiv2][query] POST https://firebasehosting.googleapis.com/v1beta1/sites/socialmedia-5f158/versions/7cac918590bf79d0:populateFiles [none]
[debug] [2020-12-19T05:49:06.244Z] >>> [apiv2][body] POST https://firebasehosting.googleapis.com/v1beta1/sites/socialmedia-5f158/versions/7cac918590bf79d0:populateFiles {"files":{"/index.html":"9cf85a1fb57e777006bcf68ba0de7b72871e96c0e7ce7b72ec2267f46c5b04aa"}}
[debug] [2020-12-19T05:49:06.609Z] <<< [apiv2][status] POST https://firebasehosting.googleapis.com/v1beta1/sites/socialmedia-5f158/versions/7cac918590bf79d0:populateFiles 200
[debug] [2020-12-19T05:49:06.609Z] <<< [apiv2][body] POST https://firebasehosting.googleapis.com/v1beta1/sites/socialmedia-5f158/versions/7cac918590bf79d0:populateFiles {"uploadRequiredHashes":["9cf85a1fb57e777006bcf68ba0de7b72871e96c0e7ce7b72ec2267f46c5b04aa"],"uploadUrl":"https://upload-firebasehosting.googleapis.com/upload/sites/socialmedia-5f158/versions/7cac918590bf79d0/files"}
[debug] [2020-12-19T05:49:06.610Z] >>> [apiv2][query] POST https://upload-firebasehosting.googleapis.com/upload/sites/socialmedia-5f158/versions/7cac918590bf79d0/files/9cf85a1fb57e777006bcf68ba0de7b72871e96c0e7ce7b72ec2267f46c5b04aa [none]
[debug] [2020-12-19T05:49:06.610Z] >>> [apiv2][body] POST https://upload-firebasehosting.googleapis.com/upload/sites/socialmedia-5f158/versions/7cac918590bf79d0/files/9cf85a1fb57e777006bcf68ba0de7b72871e96c0e7ce7b72ec2267f46c5b04aa [stream]
[debug] [2020-12-19T05:49:06.611Z] [hosting][populate queue][FINAL] {"max":546,"min":546,"avg":546,"active":0,"complete":1,"success":1,"errored":0,"retried":0,"total":1,"elapsed":547}
[debug] [2020-12-19T05:49:06.611Z] [hosting] uploads queued: 1
[debug] [2020-12-19T05:49:07.406Z] <<< [apiv2][status] POST https://upload-firebasehosting.googleapis.com/upload/sites/socialmedia-5f158/versions/7cac918590bf79d0/files/9cf85a1fb57e777006bcf68ba0de7b72871e96c0e7ce7b72ec2267f46c5b04aa 200
[debug] [2020-12-19T05:49:07.406Z] <<< [apiv2][body] POST https://upload-firebasehosting.googleapis.com/upload/sites/socialmedia-5f158/versions/7cac918590bf79d0/files/9cf85a1fb57e777006bcf68ba0de7b72871e96c0e7ce7b72ec2267f46c5b04aa [stream]
[debug] [2020-12-19T05:49:07.406Z] [hosting][upload queue][FINAL] {"max":797,"min":797,"avg":797,"active":0,"complete":1,"success":1,"errored":0,"retried":0,"total":1,"elapsed":797}
[info] + hosting[socialmedia-5f158]: file upload complete
[debug] [2020-12-19T05:49:07.408Z] [hosting] deploy completed after 1359ms
[info] i functions: updating Node.js 12 function api(us-central1)...
[debug] [2020-12-19T05:49:07.691Z] Trigger is: {"httpsTrigger":{}}
[debug] [2020-12-19T05:49:07.695Z] > refreshing access token with scopes: ["email","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","openid"]
[debug] [2020-12-19T05:49:07.695Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token
<request body omitted>
[debug] [2020-12-19T05:49:07.862Z] <<< HTTP RESPONSE 200 {"pragma":"no-cache","date":"Sat, 19 Dec 2020 05:49:07 GMT","expires":"Mon, 01 Jan 1990 00:00:00 GMT","cache-control":"no-cache, no-store, max-age=0, must-revalidate","content-type":"application/json; charset=utf-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","server":"scaffolding on HTTPServer2","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:07.874Z] >>> HTTP REQUEST PATCH https://cloudfunctions.googleapis.com/v1/projects/socialmedia-5f158/locations/us-central1/functions/api {"updateMask":"sourceUploadUrl,name,labels,runtime,environmentVariables,httpsTrigger"}
{"sourceUploadUrl":"https://storage.googleapis.com/gcf-upload-us-central1-962ccae0-e24e-4d88-b0a2-d16db2e20c76/5cf7c6db-376e-483f-8e0b-ff8032a6a9b2.zip?GoogleAccessId=service-98194542320#gcf-admin-robot.iam.gserviceaccount.com&Expires=1608358745&Signature=ZfN05IUBG8tORoQvu67AzWLhLV01cC2C2PKWNe2yNYnhASSn6moWJ6wBzNdHp7mjjP7N3iJraaeTC8Vn7FEXSJ3yi1Zn4QLzGExoi8aiWDH%2BH6AxHLSYqEzhGa6YeqJIxIgCJTg2PxjoQkirf8TwNl5Ugo4intWpfmTQx%2F1a%2BsIJ6y5Y%2Bhvi9tpAVWXGGzrs0BDrGTF1Q4VTIdh72VA3t880RuH5rea%2BtrukA97EIfj6LzKRnRahdGZPcQESJ02Zy4jiXhurO1ifYHKTeAl2ifYbWxGVZBUUqiAYQoS%2F4EMF2%2FwNvUU0PGI4MjRFgYiJzUHcXUB%2FBmUivelQ5il4fw%3D%3D","name":"projects/socialmedia-5f158/locations/us-central1/functions/api","labels":{"deployment-tool":"cli-firebase"},"httpsTrigger":{},"runtime":"nodejs12","environmentVariables":{"FIREBASE_CONFIG":"{\"projectId\":\"socialmedia-5f158\",\"databaseURL\":\"https://socialmedia-5f158-default-rtdb.firebaseio.com\",\"storageBucket\":\"socialmedia-5f158.appspot.com\",\"locationId\":\"us-central\"}"}}
[debug] [2020-12-19T05:49:08.338Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:08 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:08.339Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/projects/socialmedia-5f158/locations/-/functions
[debug] [2020-12-19T05:49:08.755Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:08 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:08.758Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c29jaWFsbWVkaWEtNWYxNTgvdXMtY2VudHJhbDEvYXBpL0ZhX21RTDdVNlgw
[debug] [2020-12-19T05:49:08.925Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:08 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:10.929Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c29jaWFsbWVkaWEtNWYxNTgvdXMtY2VudHJhbDEvYXBpL0ZhX21RTDdVNlgw
[debug] [2020-12-19T05:49:39.903Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:39 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-12-19T05:49:41.904Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c29jaWFsbWVkaWEtNWYxNTgvdXMtY2VudHJhbDEvYXBpL0ZhX21RTDdVNlgw
[debug] [2020-12-19T05:49:42.073Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 19 Dec 2020 05:49:42 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
functions: package.json indicates an outdated version of firebase-functions.
Attempt to update firebase-function via the npm package manager to start with.
Secondly functions on Firebase will require a Blaze Plan due to cloud building, please ensure this is enabled - I would highly recommend setting an alert for pricing if this is a small personal project.
Please also ensure you're using Node12 in your package.json file as previous versions of Node will no longer work with Firebase in the future (read something about this while having the same issue). Just to clarify as far as I'm aware deploying Node12 code also requires a Blaze Plan.
Finally ensure that you have modularised your project by calling multiple different versions of app, you can do this by creating a new express instance, for example: const someEndpoints1 = express() + const someEndpoints2 = express() then routing accordingly; as having multiple routes under one app caused this issue for me.
Please let me know if this fixed any issues and / or you are getting an alternative output.
So I have created a node server in firebase cloud functions and I have integrated PayPal-node-sdk. The problem is the Paypal payment works in firebase emulator mode which is localhost. but when I make "firebase deploy" and I enter the URL. it doesn't proceed and gives an error.
this is the code for now
const functions = require('firebase-functions');
var paypal = require('paypal-rest-sdk');
paypal.configure({
'mode': 'sandbox', //sandbox or live
'client_id': 'ARsx8xed9TXkfOaRqh3WkeG-uzeFqT0qebkrJKssZkmBh1TWoC1ZYXpzNr8TlBDygpROnAkA8pXVmhl2',
'client_secret': 'SECRET_KEY'
});
exports.helloWorld = functions.https.onRequest((request, response) => {
var create_payment_json = {
"intent": "sale",
"payer": {
"payment_method": "paypal"
},
"redirect_urls": {
"return_url": "http://return.url",
"cancel_url": "http://cancel.url"
},
"transactions": [{
"item_list": {
"items": [{
"name": "item",
"sku": "item",
"price": "1.00",
"currency": "USD",
"quantity": 1
}]
},
"amount": {
"currency": "USD",
"total": "1.00"
},
"description": "This is the payment description."
}]
};
paypal.payment.create(create_payment_json, function (error, payment) {
if (error) {
throw error;
} else {
console.log("Create Payment Response");
console.log(payment);
for (var index = 0; index < payment.links.length; index++) {
//Redirect user to this endpoint for redirect url
if (payment.links[index].rel === 'approval_url') {
console.log(payment.links[index].href);
response.redirect(payment.links[index].href);
}
}
}
});
});
This is the package.json
{
"name": "functions",
"description": "Cloud Functions for Firebase",
"scripts": {
"lint": "eslint .",
"serve": "firebase emulators:start --only functions",
"shell": "firebase functions:shell",
"start": "npm run shell",
"deploy": "firebase deploy --only functions",
"logs": "firebase functions:log"
},
"engines": {
"node": "12"
},
"main": "index.js",
"dependencies": {
"firebase-admin": "^9.2.0",
"firebase-functions": "^3.11.0"
},
"devDependencies": {
"eslint": "^5.12.0",
"eslint-plugin-promise": "^4.0.1",
"firebase-functions-test": "^0.2.0"
},
"private": true
}
This how it looks in localhost and works perfectly fine
And this is how it displays in the server
enter image description here
What could be the problem here?
Log file:
[2020-11-28T20:38:09.374Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[2020-11-28T20:38:09.375Z] > authorizing via signed-in user
[2020-11-28T20:38:09.376Z] [iam] checking project safedine-66679 for permissions ["cloudfunctions.functions.create","cloudfunctions.functions.delete","cloudfunctions.functions.get","cloudfunctions.functions.list","cloudfunctions.functions.update","cloudfunctions.operations.get","firebase.projects.get"]
[2020-11-28T20:38:09.379Z] >>> HTTP REQUEST POST https://cloudresourcemanager.googleapis.com/v1/projects/safedine-66679:testIamPermissions
{"permissions":["cloudfunctions.functions.create","cloudfunctions.functions.delete","cloudfunctions.functions.get","cloudfunctions.functions.list","cloudfunctions.functions.update","cloudfunctions.operations.get","firebase.projects.get"]}
[2020-11-28T20:38:10.364Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:09 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","server-timing":"gfet4t7; dur=625","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:10.366Z] >>> HTTP REQUEST POST https://iam.googleapis.com/v1/projects/safedine-66679/serviceAccounts/safedine-66679#appspot.gserviceaccount.com:testIamPermissions
{"permissions":["iam.serviceAccounts.actAs"]}
[2020-11-28T20:38:11.304Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:10 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
=== Deploying to 'safedine-66679'...
i deploying functions
Running command: npm --prefix "$RESOURCE_DIR" run lint
> functions# lint C:\Users\e7cd\Documents\safedinecloudfunctions\functions
> eslint .
+ functions: Finished running predeploy script.
[2020-11-28T20:38:15.476Z] > [functions] package.json contents: {
"name": "functions",
"description": "Cloud Functions for Firebase",
"scripts": {
"lint": "eslint .",
"serve": "firebase emulators:start --only functions",
"shell": "firebase functions:shell",
"start": "npm run shell",
"deploy": "firebase deploy --only functions",
"logs": "firebase functions:log"
},
"engines": {
"node": "12"
},
"main": "index.js",
"dependencies": {
"firebase-admin": "^9.2.0",
"firebase-functions": "^3.11.0"
},
"devDependencies": {
"eslint": "^5.12.0",
"eslint-plugin-promise": "^4.0.1",
"firebase-functions-test": "^0.2.0"
},
"private": true
}
i functions: ensuring required API cloudfunctions.googleapis.com is enabled...
i functions: ensuring required API cloudbuild.googleapis.com is enabled...
[2020-11-28T20:38:16.873Z] >>> HTTP REQUEST GET https://serviceusage.googleapis.com/v1/projects/safedine-66679/services/cloudfunctions.googleapis.com
[2020-11-28T20:38:16.873Z] >>> HTTP REQUEST GET https://serviceusage.googleapis.com/v1/projects/safedine-66679/services/runtimeconfig.googleapis.com
[2020-11-28T20:38:16.874Z] >>> HTTP REQUEST GET https://serviceusage.googleapis.com/v1/projects/safedine-66679/services/cloudbuild.googleapis.com
[2020-11-28T20:38:18.073Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:17 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:18.102Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:17 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
+ functions: required API cloudbuild.googleapis.com is enabled
[2020-11-28T20:38:18.147Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:17 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
+ functions: required API cloudfunctions.googleapis.com is enabled
[2020-11-28T20:38:18.150Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects/safedine-66679/adminSdkConfig
[2020-11-28T20:38:18.628Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:18 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
i functions: preparing functions directory for uploading...
[2020-11-28T20:38:18.630Z] >>> HTTP REQUEST GET https://runtimeconfig.googleapis.com/v1beta1/projects/safedine-66679/configs
[2020-11-28T20:38:19.072Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:18 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
i functions: packaged functions (37.56 KB) for uploading
[2020-11-28T20:38:19.249Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/projects/safedine-66679/locations/-/functions
[2020-11-28T20:38:19.983Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:19 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:19.984Z] >>> HTTP REQUEST POST https://cloudfunctions.googleapis.com/v1/projects/safedine-66679/locations/us-central1/functions:generateUploadUrl
[2020-11-28T20:38:20.811Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:20 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:20.812Z] >>> HTTP REQUEST PUT https://storage.googleapis.com/gcf-upload-us-central1-d8bc2486-f64e-4507-b510-b1d84696c343/d0b11078-1545-4bd6-b169-c922d3f11142.zip?GoogleAccessId=service-884835345747#gcf-admin-robot.iam.gserviceaccount.com&Expires=1606597700&Signature=ai0sX4ZEVHlv%2Fj%2Fmgkmc1YtZIHT4XuRU8PvtmonlUGYl5tSJU%2FTfms%2Fyqe9ul0H5hGs7%2FtgwFpbmU1o5rW1HwK4QWZzUIDjkkuS%2BSRowqjzhAFIdJfjDeHpMstXHFZu%2Buwe%2FQPvckIGRalK78kz%2FSLeRphET%2FLMLLqii1iPWpquKdEkQpnSc3wqR0OgxBP6RdGUidJrHlelukJNcB3FH0WruaWgRDfEQkSLLqJ5dINzNssh%2BYpT4LZ6kyhUV0Jk%2F4FJkHroRKP7YhGhw2m0eoPqNRKnwn2qb8vNpff8mZ4OKPN5ANT0yvmEFxLRe6szJl2T7H3f78PsR2WsM84XTFw%3D%3D
<request body omitted>
[2020-11-28T20:38:21.339Z] <<< HTTP RESPONSE 200 {"x-guploader-uploadid":"ABg5-UxNRqvU0vC4ykLP7YdMfyT3wIFx_-8bUO_CoHXy43oH0kXgZIq_mDiQ0F9pqPALaXL0pb3RIY4kxpdk7vIDvg","etag":"\"db38e2617f8e5abfd2e3331528f86eb7\"","x-goog-generation":"1606595900834314","x-goog-metageneration":"1","x-goog-hash":"crc32c=CS+02g==, md5=2zjiYX+OWr/S4zMVKPhutw==","x-goog-stored-content-length":"38464","x-goog-stored-content-encoding":"identity","vary":"Origin","content-length":"0","date":"Sat, 28 Nov 2020 20:38:20 GMT","server":"UploadServer","content-type":"text/html; charset=UTF-8","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\""}
+ functions: functions folder uploaded successfully
i functions: updating Node.js 12 function helloWorld(us-central1)...
[2020-11-28T20:38:21.347Z] Trigger is: {"httpsTrigger":{}}
i functions: updating Node.js 12 function success(us-central1)...
[2020-11-28T20:38:21.348Z] Trigger is: {"httpsTrigger":{}}
[2020-11-28T20:38:21.350Z] >>> HTTP REQUEST PATCH https://cloudfunctions.googleapis.com/v1/projects/safedine-66679/locations/us-central1/functions/helloWorld {"updateMask":"sourceUploadUrl,name,labels,runtime,environmentVariables,httpsTrigger"}
{"sourceUploadUrl":"https://storage.googleapis.com/gcf-upload-us-central1-d8bc2486-f64e-4507-b510-b1d84696c343/d0b11078-1545-4bd6-b169-c922d3f11142.zip?GoogleAccessId=service-884835345747#gcf-admin-robot.iam.gserviceaccount.com&Expires=1606597700&Signature=ai0sX4ZEVHlv%2Fj%2Fmgkmc1YtZIHT4XuRU8PvtmonlUGYl5tSJU%2FTfms%2Fyqe9ul0H5hGs7%2FtgwFpbmU1o5rW1HwK4QWZzUIDjkkuS%2BSRowqjzhAFIdJfjDeHpMstXHFZu%2Buwe%2FQPvckIGRalK78kz%2FSLeRphET%2FLMLLqii1iPWpquKdEkQpnSc3wqR0OgxBP6RdGUidJrHlelukJNcB3FH0WruaWgRDfEQkSLLqJ5dINzNssh%2BYpT4LZ6kyhUV0Jk%2F4FJkHroRKP7YhGhw2m0eoPqNRKnwn2qb8vNpff8mZ4OKPN5ANT0yvmEFxLRe6szJl2T7H3f78PsR2WsM84XTFw%3D%3D","name":"projects/safedine-66679/locations/us-central1/functions/helloWorld","labels":{"deployment-tool":"cli-firebase"},"httpsTrigger":{},"runtime":"nodejs12","environmentVariables":{"FIREBASE_CONFIG":"{\"projectId\":\"safedine-66679\",\"databaseURL\":\"https://safedine-66679.firebaseio.com\",\"storageBucket\":\"safedine-66679.appspot.com\"}"}}
[2020-11-28T20:38:21.351Z] >>> HTTP REQUEST PATCH https://cloudfunctions.googleapis.com/v1/projects/safedine-66679/locations/us-central1/functions/success {"updateMask":"sourceUploadUrl,name,labels,runtime,environmentVariables,httpsTrigger"}
{"sourceUploadUrl":"https://storage.googleapis.com/gcf-upload-us-central1-d8bc2486-f64e-4507-b510-b1d84696c343/d0b11078-1545-4bd6-b169-c922d3f11142.zip?GoogleAccessId=service-884835345747#gcf-admin-robot.iam.gserviceaccount.com&Expires=1606597700&Signature=ai0sX4ZEVHlv%2Fj%2Fmgkmc1YtZIHT4XuRU8PvtmonlUGYl5tSJU%2FTfms%2Fyqe9ul0H5hGs7%2FtgwFpbmU1o5rW1HwK4QWZzUIDjkkuS%2BSRowqjzhAFIdJfjDeHpMstXHFZu%2Buwe%2FQPvckIGRalK78kz%2FSLeRphET%2FLMLLqii1iPWpquKdEkQpnSc3wqR0OgxBP6RdGUidJrHlelukJNcB3FH0WruaWgRDfEQkSLLqJ5dINzNssh%2BYpT4LZ6kyhUV0Jk%2F4FJkHroRKP7YhGhw2m0eoPqNRKnwn2qb8vNpff8mZ4OKPN5ANT0yvmEFxLRe6szJl2T7H3f78PsR2WsM84XTFw%3D%3D","name":"projects/safedine-66679/locations/us-central1/functions/success","labels":{"deployment-tool":"cli-firebase"},"httpsTrigger":{},"runtime":"nodejs12","environmentVariables":{"FIREBASE_CONFIG":"{\"projectId\":\"safedine-66679\",\"databaseURL\":\"https://safedine-66679.firebaseio.com\",\"storageBucket\":\"safedine-66679.appspot.com\"}"}}
[2020-11-28T20:38:21.859Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:21 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:21.878Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:21 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:21.879Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/projects/safedine-66679/locations/-/functions
[2020-11-28T20:38:22.523Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:22 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:22.524Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:38:22.525Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:22.900Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:22 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:22.904Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:22 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:24.911Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:24.911Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:38:27.684Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:27 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:29.703Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:30.061Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:29 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:30.086Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:29 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:32.074Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:38:32.089Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:32.461Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:32 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:32.462Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:32 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:34.473Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:34.474Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:38:34.838Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:34 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:34.854Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:34 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:36.841Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:36.856Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:38:37.211Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:36 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:37.217Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:36 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:39.212Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvc3VjY2Vzcy9CNnR2Z3ktWmRtUQ
[2020-11-28T20:38:39.228Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:38:39.582Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:39 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:39.590Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:38:39 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[2020-11-28T20:38:41.583Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:39:22.100Z] >>> HTTP REQUEST GET https://cloudfunctions.googleapis.com/v1/operations/c2FmZWRpbmUtNjY2NzkvdXMtY2VudHJhbDEvaGVsbG9Xb3JsZC96d2NJV29QNllQdw
[2020-11-28T20:39:24.854Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Sat, 28 Nov 2020 20:39:24 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-29=\":443\"; ma=2592000,h3-T051=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
! functions[success(us-central1)]: Deployment error.
Function failed on loading user code. Error message: Error: please examine your function logs to see the error cause: https://cloud.google.com/functions/docs/monitoring/logging#viewing_logs. Additional troubleshooting documentation can be found at https://cloud.google.com/functions/docs/troubleshooting#logging
Functions deploy had errors with the following functions:
helloWorld
success
To try redeploying those functions, run:
firebase deploy --only "functions:helloWorld,functions:success"
To continue deploying other features (such as database), run:
firebase deploy --except functions
Error: Functions did not deploy properly.
C:\Users\e7cd\Documents\safedinecloudfunctions>
Log from the firebase console
3:13:13.689 am
helloWorld
Error: function terminated. Recommended action: inspect logs for termination reason. Additional troubleshooting documentation can be found at https://cloud.google.com/functions/docs/troubleshooting#logging Function invocation was interrupted.
helloWorld
Error: function terminated. Recommended action: inspect logs for termination reason. Additional troubleshooting documentation can be found at https://cloud.google.com/functions/docs/troubleshooting#logging Function invocation was interrupted.
3:13:48.825 am
helloWorld
Function execution started
3:13:49.144 am
helloWorld
Provided module can't be loaded.
From
https://github.com/paypal/PayPal-node-SDK#usage:
Add dependency 'paypal-rest-sdk' in your package.json file.
This is one reason why your function would not start.
Given that you shared your paypal access credentials publicly I strongly suggest you generate new pair and deactivate the ones you included.
When I run firebase deploy command, I would like to know which files are deployed.
I tried firebase deploy --debug, but I don't see any information about uploaded files.
[2018-05-25T09:48:26.423Z] ----------------------------------------------------------------------
[2018-05-25T09:48:26.426Z] Command: /usr/local/bin/node /usr/local/bin/firebase deploy --debug
[2018-05-25T09:48:26.427Z] CLI Version: 3.18.4
[2018-05-25T09:48:26.427Z] Platform: darwin
[2018-05-25T09:48:26.427Z] Node Version: v9.2.0
[2018-05-25T09:48:26.428Z] Time: Fri May 25 2018 11:48:26 GMT+0200 (CEST)
[2018-05-25T09:48:26.428Z] ----------------------------------------------------------------------
[2018-05-25T09:48:26.439Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[2018-05-25T09:48:26.440Z] > authorizing via signed-in user
[2018-05-25T09:48:26.441Z] > refreshing access token with scopes: ["email","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","openid"]
[2018-05-25T09:48:26.442Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token
{ refresh_token: '1/sNSNg7xxbzwVujBEzRAQ2eZHkEuT0d6A2jVVUGa-e9Jgrc8NASizU4RK7MEmNnov',
client_id: '563584335869-fgrhgmd47bqnekij5i8b5pr03ho849e6.apps.googleusercontent.com',
client_secret: 'j9iVZfS8kkCEFUPaAeJV0sAi',
grant_type: 'refresh_token',
scope: 'email https://www.googleapis.com/auth/cloud-platform https://www.googleapis.com/auth/cloudplatformprojects.readonly https://www.googleapis.com/auth/firebase openid' }
Fri May 25 2018 11:48:26 GMT+0200 (CEST)
[2018-05-25T09:48:26.585Z] <<< HTTP RESPONSE 200 cache-control=no-cache, no-store, max-age=0, must-revalidate, pragma=no-cache, expires=Mon, 01 Jan 1990 00:00:00 GMT, date=Fri, 25 May 2018 09:48:26 GMT, vary=X-Origin, Origin,Accept-Encoding, content-type=application/json; charset=UTF-8, x-content-type-options=nosniff, x-frame-options=SAMEORIGIN, x-xss-protection=1; mode=block, server=GSE, alt-svc=hq=":443"; ma=2592000; quic=51303433; quic=51303432; quic=51303431; quic=51303339; quic=51303335,quic=":443"; ma=2592000; v="43,42,41,39,35", accept-ranges=none, connection=close
[2018-05-25T09:48:26.593Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/projects/test-table
Fri May 25 2018 11:48:26 GMT+0200 (CEST)
[2018-05-25T09:48:27.222Z] <<< HTTP RESPONSE 200 server=nginx, date=Fri, 25 May 2018 09:48:27 GMT, content-type=application/json; charset=utf-8, content-length=141, connection=close, x-content-type-options=nosniff, strict-transport-security=max-age=31536000; includeSubdomains, cache-control=no-cache, no-store
[2018-05-25T09:48:27.223Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/database/test-table/tokens
Fri May 25 2018 11:48:27 GMT+0200 (CEST)
[2018-05-25T09:48:27.777Z] <<< HTTP RESPONSE 200 server=nginx, date=Fri, 25 May 2018 09:48:27 GMT, content-type=application/json; charset=utf-8, content-length=274, connection=close, x-content-type-options=nosniff, strict-transport-security=max-age=31536000; includeSubdomains, cache-control=no-cache, no-store
=== Deploying to 'test-table'...
i deploying hosting
i hosting: preparing dist directory for upload...
[2018-05-25T09:48:28.900Z] >>> HTTP REQUEST PUT https://deploy.firebase.com/v1/hosting/test-table/uploads/-LDLglCdzpfzQK77Fbrb?fileCount=2&message=
Fri May 25 2018 11:48:28 GMT+0200 (CEST)
Uploading: [ ] 0%[2018-05-25T09:48:32.752Z] <<< HTTP RESPONSE 200 server=nginx, date=Fri, 25 May 2018 09:48:32 GMT, content-type=application/json; charset=utf-8, content-length=49, connection=close, access-control-allow-origin=*, access-control-allow-methods=GET, PUT, POST, DELETE, OPTIONS, strict-transport-security=max-age=31556926; includeSubDomains; preload, x-content-type-options=nosniff
[2018-05-25T09:48:32.753Z] [hosting] .tgz uploaded successfully, waiting for extraction
✔ hosting: 2 files uploaded successfully
[2018-05-25T09:48:33.642Z] [hosting] deploy completed after 5190ms
[2018-05-25T09:48:33.643Z] >>> HTTP REQUEST POST https://deploy.firebase.com/v1/projects/test-table/releases
{ hosting:
{ public: 'dist',
ignore: [ 'firebase.json', '**/.*', '**/node_modules/**' ],
version: '-LDLglCdzpfzQK77Fbrb',
prefix: '-LDLglCdzpfzQK77Fbrb/',
manifest: [] } }
Fri May 25 2018 11:48:33 GMT+0200 (CEST)
[2018-05-25T09:48:34.951Z] <<< HTTP RESPONSE 200 server=nginx, date=Fri, 25 May 2018 09:48:34 GMT, content-type=application/json; charset=utf-8, content-length=34, connection=close, access-control-allow-origin=*, access-control-allow-methods=GET, PUT, POST, DELETE, OPTIONS, strict-transport-security=max-age=31556926; includeSubDomains; preload, x-content-type-options=nosniff
✔ Deploy complete!
The only information the Firebase CLI shows is:
i hosting: preparing dist directory for upload...
So this means that everything in your dist directory is deployed, and nothing else.
Since the files are uploaded as a single .tgz file, there is no progress report for individual files.
I am trying to deploy this:
firestore.rules file:
service cloud.firestore {
match /databases/{database}/documents {
match /documents/{document} {
// must be authenticated to view or create doc
allow create, read: if request.auth != null;
// must be your own doc to update
allow update, delete: if request.auth.uid == resource.data.uid;
}
}
}
with firebase deploy --only firestore:rules
but I am getting an ungooglable error.
Here is my firebase-debug.log:
[debug] [2018-02-25T14:55:55.801Z] ----------------------------------------------------------------------
[debug] [2018-02-25T14:55:55.803Z] Command: /Users/swyx/.nvm/versions/node/v8.5.0/bin/node /Users/swyx/.nvm/versions/node/v8.5.0/bin/firebase deploy --only firestore:rules
[debug] [2018-02-25T14:55:55.803Z] CLI Version: 3.14.0
[debug] [2018-02-25T14:55:55.804Z] Platform: darwin
[debug] [2018-02-25T14:55:55.804Z] Node Version: v8.5.0
[debug] [2018-02-25T14:55:55.804Z] Time: Sun Feb 25 2018 09:55:55 GMT-0500 (EST)
[debug] [2018-02-25T14:55:55.804Z] ----------------------------------------------------------------------
[debug]
[debug] [2018-02-25T14:55:55.818Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2018-02-25T14:55:55.818Z] > authorizing via signed-in user
[debug] [2018-02-25T14:55:55.819Z] > refreshing access token with scopes: ["email","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","openid"]
[debug] [2018-02-25T14:55:55.820Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token { refresh_token: '1/redacted',
client_id: '563584335869-redacted.apps.googleusercontent.com',
client_secret: 'redacted',
grant_type: 'refresh_token',
scope: 'email https://www.googleapis.com/auth/cloud-platform https://www.googleapis.com/auth/cloudplatformprojects.readonly https://www.googleapis.com/auth/firebase openid' }
Sun Feb 25 2018 09:55:55 GMT-0500 (EST)
[debug] [2018-02-25T14:55:55.935Z] <<< HTTP RESPONSE 200
[debug] [2018-02-25T14:55:55.943Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/projects/testfirepup1
Sun Feb 25 2018 09:55:55 GMT-0500 (EST)
[debug] [2018-02-25T14:55:56.224Z] <<< HTTP RESPONSE 200
[debug] [2018-02-25T14:55:56.225Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/database/testfirepup1/tokens
Sun Feb 25 2018 09:55:56 GMT-0500 (EST)
[debug] [2018-02-25T14:55:56.699Z] <<< HTTP RESPONSE 200
[info] 1
[info]
[info] === Deploying to 'testfirepup1'...
[info]
[info] i deploying firestore
[info] i firestore: checking firestore.rules for compilation errors...
[debug] [2018-02-25T14:55:56.917Z] >>> HTTP REQUEST POST https://firebaserules.googleapis.com/v1/projects/testfirepup1:test { source: { files: [ [Object] ] } }
Sun Feb 25 2018 09:55:56 GMT-0500 (EST)
[debug] [2018-02-25T14:55:57.103Z] <<< HTTP RESPONSE 200
[info] ✔ firestore: rules file firestore.rules compiled successfully
[info] i firestore: uploading rules firestore.rules...
[debug] [2018-02-25T14:55:57.105Z] >>> HTTP REQUEST POST https://firebaserules.googleapis.com/v1/projects/testfirepup1/rulesets { source: { files: [ [Object] ] } }
Sun Feb 25 2018 09:55:57 GMT-0500 (EST)
[debug] [2018-02-25T14:55:57.416Z] <<< HTTP RESPONSE 200
[debug] [2018-02-25T14:55:57.416Z] [rules] created ruleset projects/testfirepup1/rulesets/6e8dfacc-8c69-4fd6-95b4-a28593bdb8c1
[debug] [2018-02-25T14:55:57.417Z] [rules] releasing cloud.firestore with ruleset projects/testfirepup1/rulesets/6e8dfacc-8c69-4fd6-95b4-a28593bdb8c1
[debug] [2018-02-25T14:55:57.417Z] >>> HTTP REQUEST PUT https://firebaserules.googleapis.com/v1/projects/testfirepup1/releases/cloud.firestore { name: 'projects/testfirepup1/releases/cloud.firestore',
rulesetName: 'projects/testfirepup1/rulesets/6e8dfacc-8c69-4fd6-95b4-a28593bdb8c1' }
Sun Feb 25 2018 09:55:57 GMT-0500 (EST)
[debug] [2018-02-25T14:55:57.525Z] <<< HTTP RESPONSE 404
[debug] [2018-02-25T14:55:57.526Z] <<< HTTP RESPONSE BODY <!DOCTYPE html>
<html lang=en>
<meta charset=utf-8>
<meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width">
<title>Error 404 (Not Found)!!1</title>
<style>
*{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}#media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}#logo{background:url(//www.google.com/images/branding/googlelogo/1x/googlelogo_color_150x54dp.png) no-repeat;margin-left:-5px}#media only screen and (min-resolution:192dpi){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat 0% 0%/100% 100%;-moz-border-image:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) 0}}#media only screen and (-webkit-min-device-pixel-ratio:2){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat;-webkit-background-size:100% 100%}}#logo{display:inline-block;height:54px;width:150px}
</style>
<a href=//www.google.com/><span id=logo aria-label=Google></span></a>
<p><b>404.</b> <ins>That’s an error.</ins>
<p>The requested URL <code>/v1/projects/testfirepup1/releases/cloud.firestore</code> was not found on this server. <ins>That’s all we know.</ins>
[debug] [2018-02-25T14:55:57.527Z] TypeError: Cannot create property 'error' on string '<!DOCTYPE html>
<html lang=en>
<meta charset=utf-8>
<meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width">
<title>Error 404 (Not Found)!!1</title>
<style>
*{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}#media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}#logo{background:url(//www.google.com/images/branding/googlelogo/1x/googlelogo_color_150x54dp.png) no-repeat;margin-left:-5px}#media only screen and (min-resolution:192dpi){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat 0% 0%/100% 100%;-moz-border-image:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) 0}}#media only screen and (-webkit-min-device-pixel-ratio:2){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat;-webkit-background-size:100% 100%}}#logo{display:inline-block;height:54px;width:150px}
</style>
<a href=//www.google.com/><span id=logo aria-label=Google></span></a>
<p><b>404.</b> <ins>That’s an error.</ins>
<p>The requested URL <code>/v1/projects/testfirepup1/releases/cloud.firestore</code> was not found on this server. <ins>That’s all we know.</ins>
'
at module.exports (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/lib/responseToError.js:11:16)
at Request._callback (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/lib/api.js:43:25)
at Request.self.callback (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/node_modules/request/request.js:186:22)
at emitTwo (events.js:125:13)
at Request.emit (events.js:213:7)
at Request.<anonymous> (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/node_modules/request/request.js:1163:10)
at emitOne (events.js:115:13)
at Request.emit (events.js:210:7)
at IncomingMessage.<anonymous> (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/node_modules/request/request.js:1085:12)
at Object.onceWrapper (events.js:314:30)
[error]
[error] Error: An unexpected error has occurred.
[debug] [2018-02-25T14:56:50.487Z] ----------------------------------------------------------------------
[debug] [2018-02-25T14:56:50.489Z] Command: /Users/swyx/.nvm/versions/node/v8.5.0/bin/node /Users/swyx/.nvm/versions/node/v8.5.0/bin/firebase deploy --only firestore:rules
[debug] [2018-02-25T14:56:50.490Z] CLI Version: 3.14.0
[debug] [2018-02-25T14:56:50.490Z] Platform: darwin
[debug] [2018-02-25T14:56:50.490Z] Node Version: v8.5.0
[debug] [2018-02-25T14:56:50.491Z] Time: Sun Feb 25 2018 09:56:50 GMT-0500 (EST)
[debug] [2018-02-25T14:56:50.491Z] ----------------------------------------------------------------------
[debug]
[debug] [2018-02-25T14:56:50.505Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2018-02-25T14:56:50.505Z] > authorizing via signed-in user
[debug] [2018-02-25T14:56:50.507Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/projects/testfirepup1
Sun Feb 25 2018 09:56:50 GMT-0500 (EST)
[debug] [2018-02-25T14:56:51.081Z] <<< HTTP RESPONSE 200
[debug] [2018-02-25T14:56:51.082Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/database/testfirepup1/tokens
Sun Feb 25 2018 09:56:51 GMT-0500 (EST)
[debug] [2018-02-25T14:56:51.586Z] <<< HTTP RESPONSE 200
[info] 1
[info]
[info] === Deploying to 'testfirepup1'...
[info]
[info] i deploying firestore
[info] i firestore: checking firestore.rules for compilation errors...
[debug] [2018-02-25T14:56:51.847Z] >>> HTTP REQUEST POST https://firebaserules.googleapis.com/v1/projects/testfirepup1:test { source: { files: [ [Object] ] } }
Sun Feb 25 2018 09:56:51 GMT-0500 (EST)
[debug] [2018-02-25T14:56:52.036Z] <<< HTTP RESPONSE 200
[info] ✔ firestore: rules file firestore.rules compiled successfully
[info] i firestore: uploading rules firestore.rules...
[debug] [2018-02-25T14:56:52.038Z] >>> HTTP REQUEST POST https://firebaserules.googleapis.com/v1/projects/testfirepup1/rulesets { source: { files: [ [Object] ] } }
Sun Feb 25 2018 09:56:52 GMT-0500 (EST)
[debug] [2018-02-25T14:56:52.331Z] <<< HTTP RESPONSE 200
[debug] [2018-02-25T14:56:52.331Z] [rules] created ruleset projects/testfirepup1/rulesets/e1d12cdc-2551-42eb-957a-25e7a9aa7bca
[debug] [2018-02-25T14:56:52.332Z] [rules] releasing cloud.firestore with ruleset projects/testfirepup1/rulesets/e1d12cdc-2551-42eb-957a-25e7a9aa7bca
[debug] [2018-02-25T14:56:52.332Z] >>> HTTP REQUEST PUT https://firebaserules.googleapis.com/v1/projects/testfirepup1/releases/cloud.firestore { name: 'projects/testfirepup1/releases/cloud.firestore',
rulesetName: 'projects/testfirepup1/rulesets/e1d12cdc-2551-42eb-957a-25e7a9aa7bca' }
Sun Feb 25 2018 09:56:52 GMT-0500 (EST)
[debug] [2018-02-25T14:56:52.444Z] <<< HTTP RESPONSE 404
[debug] [2018-02-25T14:56:52.444Z] <<< HTTP RESPONSE BODY <!DOCTYPE html>
<html lang=en>
<meta charset=utf-8>
<meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width">
<title>Error 404 (Not Found)!!1</title>
<style>
*{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}#media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}#logo{background:url(//www.google.com/images/branding/googlelogo/1x/googlelogo_color_150x54dp.png) no-repeat;margin-left:-5px}#media only screen and (min-resolution:192dpi){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat 0% 0%/100% 100%;-moz-border-image:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) 0}}#media only screen and (-webkit-min-device-pixel-ratio:2){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat;-webkit-background-size:100% 100%}}#logo{display:inline-block;height:54px;width:150px}
</style>
<a href=//www.google.com/><span id=logo aria-label=Google></span></a>
<p><b>404.</b> <ins>That’s an error.</ins>
<p>The requested URL <code>/v1/projects/testfirepup1/releases/cloud.firestore</code> was not found on this server. <ins>That’s all we know.</ins>
[debug] [2018-02-25T14:56:52.446Z] TypeError: Cannot create property 'error' on string '<!DOCTYPE html>
<html lang=en>
<meta charset=utf-8>
<meta name=viewport content="initial-scale=1, minimum-scale=1, width=device-width">
<title>Error 404 (Not Found)!!1</title>
<style>
*{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}#media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}#logo{background:url(//www.google.com/images/branding/googlelogo/1x/googlelogo_color_150x54dp.png) no-repeat;margin-left:-5px}#media only screen and (min-resolution:192dpi){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat 0% 0%/100% 100%;-moz-border-image:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) 0}}#media only screen and (-webkit-min-device-pixel-ratio:2){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat;-webkit-background-size:100% 100%}}#logo{display:inline-block;height:54px;width:150px}
</style>
<a href=//www.google.com/><span id=logo aria-label=Google></span></a>
<p><b>404.</b> <ins>That’s an error.</ins>
<p>The requested URL <code>/v1/projects/testfirepup1/releases/cloud.firestore</code> was not found on this server. <ins>That’s all we know.</ins>
'
at module.exports (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/lib/responseToError.js:11:16)
at Request._callback (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/lib/api.js:43:25)
at Request.self.callback (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/node_modules/request/request.js:186:22)
at emitTwo (events.js:125:13)
at Request.emit (events.js:213:7)
at Request.<anonymous> (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/node_modules/request/request.js:1163:10)
at emitOne (events.js:115:13)
at Request.emit (events.js:210:7)
at IncomingMessage.<anonymous> (/Users/swyx/.nvm/versions/node/v8.5.0/lib/node_modules/firebase-tools/node_modules/request/request.js:1085:12)
at Object.onceWrapper (events.js:314:30)
[error]
[error] Error: An unexpected error has occurred.
I can't tell what's wrong so I have no idea what to fix. Please help!
The OP indicated in a comment that the failure was the result was not having the latest version of the Firebase CLI. To see the installed version number, use firebase -V.
Because features are continuously being added in new versions of the Firebase CLI, the documentation recommends frequently updating to ensure you have the latest version:
In many cases, new features and bug fixes are available only with the
latest version of the Firebase CLI and the firebase-functions SDK.
It's a good practice to frequently update both the Firebase CLI and
the SDK with these commands inside the functions folder of your
Firebase project:
npm install firebase-functions#latest firebase-admin#latest --save
npm install -g firebase-tools
For reference, the Firebase CLI is open-source and is available here.
It was solved by updating the firebase-tools version. breaking change from 3.14 to 3.17 :( Thank you very much #bob snyder.
Our app sends some messages to our servers via FCM Upstream. We have two servers connected as clients.
Recently, we've noticed that many messages (>50%) are received twice. Often on different servers, but sometimes on the same server.
Unsure where to go from here.
Logs of one message being received twice follow:
Fri, 18 Nov 2016 21:39:17 GMT xmpp:connection receive:
<message to="xxxx#gcm.googleapis.com" from="devices#gcm.googleapis.com" type="normal">
<gcm xmlns="google:mobile:data">
{"data":
{"userInfo":"{}",
"path":"v1\/patient\/checkIn\/usage",
"method":"POST",
"body":"{}",
"dest":"https:\/\/api.stg.triggrhealth.com\/api\/v1"
},
"time_to_live":43200,
"from":"f5LDS516Eu8:APA91bGEkzwXlmXRpfui6T01QM6V3pOY8p3nSkZMUfYkDYjRxu6Xa64Bh0Boc3so8X8royBA1v4PaGjPcUW6JI0pcZL7UK9P4LEqgVThfNQKGW8DZMhTEM-JDodDvUPjGpbPA-zdYYQb",
"message_id":"1479505157658",
"category":"com.triggrhealth.prototype.stage"
}
</gcm>
</message>
Fri, 18 Nov 2016 21:39:17 GMT xmpp:connection send:
<gcm xmlns="google:mobile:data">
{"to":"f5LDS516Eu8:APA91bGEkzwXlmXRpfui6T01QM6V3pOY8p3nSkZMUfYkDYjRxu6Xa64Bh0Boc3so8X8royBA1v4PaGjPcUW6JI0pcZL7UK9P4LEqgVThfNQKGW8DZMhTEM-JDodDvUPjGpbPA-zdYYQb",
"message_id":"1479505157658",
"message_type":"ack"
}
</gcm>
Fri, 18 Nov 2016 21:42:28 GMT xmpp:connection receive:
<message to="xxxx#gcm.googleapis.com" from="devices#gcm.googleapis.com" type="normal">
<gcm xmlns="google:mobile:data">
{"data":
{"userInfo":"{}",
"path":"v1\/patient\/checkIn\/usage",
"method":"POST",
"body":"{}",
"dest":"https:\/\/api.stg.triggrhealth.com\/api\/v1"
},
"time_to_live":43200,
"from":"f5LDS516Eu8:APA91bGEkzwXlmXRpfui6T01QM6V3pOY8p3nSkZMUfYkDYjRxu6Xa64Bh0Boc3so8X8royBA1v4PaGjPcUW6JI0pcZL7UK9P4LEqgVThfNQKGW8DZMhTEM-JDodDvUPjGpbPA-zdYYQb",
"message_id":"1479505157658",
"category":"com.triggrhealth.prototype.stage"
}
</gcm>
</message>
Fri, 18 Nov 2016 21:42:28 GMT xmpp:connection send:
<gcm xmlns="google:mobile:data">
{"to":"f5LDS516Eu8:APA91bGEkzwXlmXRpfui6T01QM6V3pOY8p3nSkZMUfYkDYjRxu6Xa64Bh0Boc3so8X8royBA1v4PaGjPcUW6JI0pcZL7UK9P4LEqgVThfNQKGW8DZMhTEM-JDodDvUPjGpbPA-zdYYQb",
"message_id":"1479505157658",
"message_type":"ack"
}
</gcm>
You may want to check and try sending an ACK message. As mentioned,
In response to an upstream message, the app server must use the same connection to send an ACK message containing the unique message ID. If GCM does not receive an ACK, it may retry sending the message to the app server.
Here's the sample code:
<message id="">
<gcm xmlns="google:mobile:data">
{
"to":"REGID",
"message_id":"m-123"
"message_type":"ack"
}
</gcm>
</message>
Lastly, please also see the XMPP Connection Server Reference for more information about upstream message syntax.