我尝试用firebase emulators:start运行函数模拟器,但得到一个错误:
❯ firebase emulators:start
i emulators: Starting emulators: functions
⚠ functions: The following emulators are not running, calls to these services from the Functions emulator will affect production: auth, firestore, database, hosting, pubsub, storage
✔ functions: Using node@14 from host.
i ui: Emulator UI logging to ui-debug.log
i functions: Watching "/Users/inlined/git/junkdrawer/functions" for Cloud Functions...
⚠ functions: Cannot find module '/Users/inlined/git/junkdrawer/functions/node_modules/firebase-functions/lib/providers/https'
Require stack:
- /Users/inlined/.nvm/versions/node/v14.16.0/lib/node_modules/firebase-tools/lib/emulator/functionsEmulatorRuntime.js
⚠ Your function was killed because it raised an unhandled error.发布于 2021-08-12 01:32:01
对此我很抱歉,都是我的错。在firebase-functions软件开发工具包的版本3.15.0和3.15.1中,我们重构了一些文件层次结构,而没有意识到仿真器团队修补了一个未记录的文件/函数。
即将发布的firebase-tools 3.15.2版本同时处理旧路径和新路径。您可以使用以下命令修复错误:
npm install -g firebase-toolshttps://stackoverflow.com/questions/68750602
复制相似问题