“Unable to launch firebase emulators ui” 可以翻译为 “无法启动 Firebase 模拟器界面”。

huangapple go评论79阅读模式
英文:

Unable to launch firebase emulators ui

问题

Hello everybody: 我无法启动我的模拟器,firebase初始化正常,端口正常,问题似乎来自UI。有人可以帮助我吗?

(base) jean-charlesdubien@airdejencharles firebase-demo-project % firebase emulators:start
i  emulators: Starting emulators: auth, functions, firestore, hosting, storage
⚠  functions: The following emulators are not running, calls to these services from the Functions emulator will affect production: database, pubsub
i  firestore: Firestore Emulator logging to firestore-debug.log
✔  firestore: Firestore Emulator UI websocket is running on 9150.
i  hosting[flutter-ultimate-ae8a4]: Serving hosting files from: public
✔  hosting[flutter-ultimate-ae8a4]: Local server: http://127.0.0.1:5002/
i  ui: Emulator UI logging to ui-debug.log
⚠  ui: Fatal error occurred:
   Emulator UI has exited with code: 1,
   stopping all running emulators
i  ui: Stopping Emulator UI
⚠  ui: Error stopping Emulator UI
i  functions: Stopping Functions Emulator
i  hosting: Stopping Hosting Emulator
i  firestore: Stopping Firestore Emulator
i  auth: Stopping Authentication Emulator
i  storage: Stopping Storage Emulator
i  eventarc: Stopping Eventarc Emulator
i  hub: Stopping emulator hub
i  logging: Stopping Logging Emulator

Node在19版本后未能成功降级。尝试在Rosetta和M1终端上使用Java JRE 19 Mac M1。

谢谢。

降级Node版本从19到16
重试初始化和下载模拟器
尝试从M1和Rosetta终端运行。

编辑:模式--调试

Node.js v18.15.0
{"metadata":{"emulator":{"name":"ui"},"message":"/Users/jean-charlesdubien/.cache/firebase/emulators/ui-v1.11.4/server/server.js:569\n re"use strict";\n ^^^^^^^^^^^^\n\nSyntaxError: Unexpected string\n at internalCompileFunction (node:internal/vm:73:18)\n at wrapSafe (node:internal/modules/cjs/loader:1176:20)\n at Module._compile (node:internal/modules/cjs/loader:1218:27)\n at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)\n at Module.load (node:internal/modules/cjs/loader:1117:32)\n at Module._load (node:internal/modules/cjs/loader:958:12)\n at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)\n at node:internal/main/run_main_module:23:47\n\nNode.js v18.15.0"}}
⚠ ui: 致命错误发生:
模拟器UI以代码1退出,停止所有正在运行的模拟器{"metadata":{"emulator":{"name":"ui"},"message":"Fatal error occurred: \n Emulator UI has exited with code: 1, \n stopping all running emulators"}}

英文:

Hello everybody: i can't launch my emulators , firebase init ok , ports ok , the problem seems to come from the ui . Anybody could help me ?

(base) jean-charlesdubien@airdejencharles firebase-demo-project % firebase emulators:start
i  emulators: Starting emulators: auth, functions, firestore, hosting, storage
⚠  functions: The following emulators are not running, calls to these services from the Functions emulator will affect production: database, pubsub
i  firestore: Firestore Emulator logging to firestore-debug.log
✔  firestore: Firestore Emulator UI websocket is running on 9150.
i  hosting[flutter-ultimate-ae8a4]: Serving hosting files from: public
✔  hosting[flutter-ultimate-ae8a4]: Local server: http://127.0.0.1:5002/
i  ui: Emulator UI logging to ui-debug.log
⚠  ui: Fatal error occurred: 
   Emulator UI has exited with code: 1, 
   stopping all running emulators
i  ui: Stopping Emulator UI
⚠  ui: Error stopping Emulator UI
i  functions: Stopping Functions Emulator
i  hosting: Stopping Hosting Emulator
i  firestore: Stopping Firestore Emulator
i  auth: Stopping Authentication Emulator
i  storage: Stopping Storage Emulator
i  eventarc: Stopping Eventarc Emulator
i  hub: Stopping emulator hub
i  logging: Stopping Logging Emulator

Node @19 then downgraded unsuccesfully. java jre19 mac M1 , tried on rosetta and M1 terminal

Thank you

downgrade node from 19 to 16
retry init and download emulators
try from terminal M1 and rosetta .

EDIT : mode -- debug

Node.js v18.15.0
{"metadata":{"emulator":{"name":"ui"},"message":"/Users/jean-charlesdubien/.cache/firebase/emulators/ui-v1.11.4/server/server.js:569\n re"use strict";\n ^^^^^^^^^^^^\n\nSyntaxError: Unexpected string\n at internalCompileFunction (node:internal/vm:73:18)\n at wrapSafe (node:internal/modules/cjs/loader:1176:20)\n at Module._compile (node:internal/modules/cjs/loader:1218:27)\n at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)\n at Module.load (node:internal/modules/cjs/loader:1117:32)\n at Module._load (node:internal/modules/cjs/loader:958:12)\n at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)\n at node:internal/main/run_main_module:23:47\n\nNode.js v18.15.0\n"}}
⚠ ui: Fatal error occurred:
Emulator UI has exited with code: 1,
stopping all running emulators {"metadata":{"emulator":{"name":"ui"},"message":"Fatal error occurred: \n Emulator UI has exited with code: 1, \n stopping all running emulators"}}

答案1

得分: 3

我降级到 Node.js v18.15.0 后问题解决。之前我安装了 v18.16.0
链接:https://nodejs.org/dist/v18.15.0/

英文:

It worked for me to downgrade to Node.js v18.15.0. I've had v18.16.0 installed before.
https://nodejs.org/dist/v18.15.0/

答案2

得分: 2

降级版本对我有帮助,就像克里斯一样。

此外,为了让一切正常工作,您需要删除缓存,在我的情况下,路径是"/Users/dmitroserdun/.cache/firebase"。

英文:

Downgrading the version helped me, as Chris.

Also, for everything to work, you need to delete the cache, in my case, it is the path "/Users/dmitroserdun/.cache/firebase"

答案3

得分: 0

Node 19 是实验性的,不受 Node 或 Firebase 官方支持:

https://github.com/firebase/firebase-tools/issues/5608

请降级到 18 版本,如果仍然遇到问题,请回复。

英文:

Node 19 is experimental and not officially supported (by Node or Firebase):

https://github.com/firebase/firebase-tools/issues/5608

Please downgrade to 18 and reply if you're still having issues.

答案4

得分: 0

你可以使用Docker来做这个,这更加干净,我使用这个镜像 https://hub.docker.com/r/spine3/firebase-emulator.

英文:

You can use docker for that its more a clean way, Im use this image
https://hub.docker.com/r/spine3/firebase-emulator

答案5

得分: 0

降级至 Node.js 版本 v18.15.0
删除缓存(在 Windows 上为 /Users/user/.cache/firebase)

英文:

Answers above, note the combination of:

  • Downgrade to Node.js v18.15.0
  • Delete cache (on Windows /Users/user/.cache/firebase)

huangapple
  • 本文由 发表于 2023年3月21日 03:07:06
  • 转载请务必保留本文链接:https://go.coder-hub.com/75794346.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定