I'm following a course of ionic and I need to store a picture on firebase database, at that point we should install firebase-tools, which I do by executing as admin:
npm install -g firebase-tools
But then the course says you should execute:
firebase init
and then I receive the following error:
Error: An unexpected error has occurred.
This generic error with nothing else.
Any ideas of how to solve this?
If you execute:
firebase init --debug
This gives you more info about the error.
It might be something about credentials or login information which can be solved by executing:
firebase login
Related
Upgraded firebase to version 11.15.0 as described here
https://firebase.blog/posts/2022/10/whats-new-at-Firebase-Sumit-2022
==> firebase --version
11.15.0
Ran
==> firebase experiments:enablewebframeworks
Got error
Error: experiments:enablewebframeworks is not a Firebase command
There seems to be a documentation error. There must be a space between the enable & webframeworks
Try to run :
firebase experiments:enable webframeworks
Instead of :
firebase experiments:enablewebframeworks
I tried with firebase experiments:enable webframeworks and was able to execute the command successfully.
You can refer this github link.
i got wired issued with firebase deployment using:
firebase deploy -P dev
the error is
✔ functions[testFunction(us-central1)] Successful update operation.
Invalid source token
looks like its happen to new functions that created
when i tried to deploy specific function using:
firebase -deploy -P dev --only functions:name
its working
when i run and deploy all functions and all my apps i am getting the above error with no information
also the logs from google cloud function is:
status: {
code: 9
message: "Invalid source token"
}
firebase tools version 11.0.0
node: 14.19.3
I would suggest upgrading to atleast node 16 as there's an open issue regarding the "Invalid Source Token" on your current firebase-tools version. There's already a pull request regarding that issue and it will be fixed on the upcoming updates. Here's the github issue for reference.
When I try to run my localhost using yarn dev it shows this error:
yarn run v1.22.4 $ next -p 7777 ready - started server on
0.0.0.0:7777, url: http://localhost:7777 TypeError: _jestWorker.Worker is not a constructor
at Object.loadWebpackHook (D:\isc-web\isc-front\node_modules\next\dist\server\config-utils.js:67:20)
at Object.loadConfig [as default] (D:\isc-web\isc-front\node_modules\next\dist\server\config.js:332:29)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at async NextServer.loadConfig (D:\isc-web\isc-front\node_modules\next\dist\server\next.js:112:22)
error Command failed with exit code 1. info Visit
https://yarnpkg.com/en/docs/cli/run for documentation about this
command.
It was all working fine before I did npm install --save-dev babel-plugin-styled-components even though I canceled the changes by using git checkout -- . but still got the same problem
If you cancelled dependency changes with git checkout your node_modules may still have the old dependencies installed. Try running npm i again to see if getting updated dependencies resolves the issue.
I can't tell much from this error message and I don't know how far along your project is... Have you seen the official Next.js + styled-components example? https://github.com/vercel/next.js/tree/canary/examples/with-styled-components
Perhaps if you try setting up the library this way instead?
After changing a cloud function I’m getting the following error for any write operation to my database: FirebaseError: invalid stream token. After changing the functions back and redeploying, the error still remains. I was unable to find any reference to this error in Firebase docs. Anyone know what this is about?
I "solved" this. For anyone else who runs into the error:
> rm package-lock.json
> rm -rf node-modules/
> npm install
Would still be nice to have a reference to this somewhere though.
firebase login --debug
i Firebase optionally collects CLI usage and error reporting information to help improve our products. Data is collected in accordance with Google's privacy policy (https://policies.google.com/privacy) and is not used to identify you.
? Allow Firebase to collect CLI usage and error reporting information? Yes
i To change your data collection preference at any time, run firebase logout and log in again.
Visit this URL on this device to log in:
https://accounts.google.com/o/oauth2/auth?client_id=563584335869-fgrhgmd47bqnekij5i8b5pr03ho849e6.apps.googleusercontent.com&scope=email%20openid%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fcloudplatformprojects.readonly%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Ffirebase%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fcloud-platform&response_type=code&state=151882733&redirect_uri=http%3A%2F%2Flocalhost%3A9005
Waiting for authentication...
[2020-04-21T13:30:57.183Z] Error: spawn cmd ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:240:19)
at onErrorNT (internal/child_process.js:415:16)
at process._tickCallback (internal/process/next_tick.js:63:19)
Error: An unexpected error has occurred.
Having trouble? Try again or contact support with contents of firebase-debug.log
This problem's solution may depend on the type of OS one is using if you are using window first run cmd as an administrator then type firebase login this should solve this problem and if your OS is Linux you may need to do sudo firebase login can be solved by