0

I am using firebase could functions for the first time. I am having trouble deploying the functions. It gives me the below error:

error in my termimal

Below is my package.json file:

{
  "name": "functions",
  "description": "Cloud Functions for Firebase",
  "scripts": {
  "lint": "eslint .",
  "serve": "firebase serve --only functions",
  "shell": "firebase functions:shell",
  "start": "npm run shell",
  "deploy": "firebase deploy --only functions",
  "logs": "firebase functions:log"
},
 "engines": {
 "node": "8"
},
"dependencies": {
 "@google-cloud/logging": "^4.5.2",
 "firebase-admin": "^7.3.0",
 "firebase-functions": "^2.3.1",
 "stripe": "^6.34.0"
},
"devDependencies": {
 "eslint": "^5.12.0",
 "eslint-plugin-promise": "^4.0.1",
 "firebase-functions-test": "^0.1.6"
 },
"private": true
}

Below are the logs:

TypeError: Cannot read property 'pipesCount' of undefined at module.exports.Readable.pipe (_stream_readable.js:545:16) at module.exports.ZipArchiveOutputStream._smartStream (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/compress-commons/lib/archivers/zip/zip-archive-output-stream.js:184:11) at module.exports.ZipArchiveOutputStream._appendBuffer (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/compress-commons/lib/archivers/zip/zip-archive-output-stream.js:82:10) at module.exports.ArchiveOutputStream.entry (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/compress-commons/lib/archivers/archive-output-stream.js:86:10) at module.exports.ZipStream.entry (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/zip-stream/index.js:157:49) at Zip.append (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/archiver/lib/plugins/zip.js:54:15) at Archiver._moduleAppend (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/archiver/lib/core.js:179:16) at Archiver._onQueueTask (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/archiver/lib/core.js:400:8) at /home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/async/dist/async.js:4096:9 at Object.process (/home/appinventiv-pc/.nvm/versions/node/v8.0.0/lib/node_modules/firebase-tools/node_modules/async/dist/async.js:2344:17)

If there is any other information i need to provide please let me know. I am new to firebase cloud functions and node.

6
  • Run the deploy command with --debug and edit the question to show the output that shows the specific error. Commented May 13, 2019 at 19:58
  • @DougStevenson added the logs. Please check
    – nick.tdr
    Commented May 13, 2019 at 20:11
  • Please don't show screenshots of text. Just copy the text into the question to make it easier to read and search. Also please note the version of the Firebase CLI you're using (and make sure you're using the latest). Commented May 13, 2019 at 20:12
  • I updated the version of Firebase CLI but that din't help either
    – nick.tdr
    Commented May 13, 2019 at 20:22
  • I'd contact Firebase support with a bug report. support.google.com/firebase/contact/support?page=bug_or_feature Commented May 13, 2019 at 20:25

1 Answer 1

1

You are using a very old version of node (8.0.0) that has a bug. Upgrade your node version to something more recent.

(I found this information by doing a search with your error message.)

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.