firebase - 模拟 Firebase 数据库触发函数错误:尚不支持服务“firebaseio.com”
问题描述
更新:已解决!npm包firebase-tools
需要更新到最新版本。
我正在尝试firebase experimental:functions:shell
在我的终端中使用 Firebase 的命令来模拟/测试我的云功能(特别是数据库触发器)。
这是结果,我的 HTTP 函数模拟但我得到每个Firebase 数据库触发器函数的错误:
Your requested "node" version "6" doesn't match your global version "8"
✔ functions: Emulator started at http://localhost:5001
i functions: Watching "/Users/****/Documents/Websites/***** - Other/cloud-functions/" for Cloud Functions...
⚠ Default "firebase-admin" instance created!
⚠ Ignoring trigger "CF_NAME_HIDDEN_1" because the service "firebaseio.com" is not yet supported.
⚠ Ignoring trigger "CF_NAME_HIDDEN_2" because the service "firebaseio.com" is not yet supported.
⚠ Ignoring trigger "CF_NAME_HIDDEN_3" because the service "firebaseio.com" is not yet supported.
i functions: HTTP trigger initialized at http://localhost:5001/****-****/us-central1/CF_NAME_HIDDEN_4
我不明白为什么会收到此错误或这意味着什么:
忽略触发器......因为尚不支持服务“firebaseio.com”。
我的 package.json 包括:
"firebase": "4.6.2",
"firebase-admin": "^7.4.0",
"firebase-functions": "^2.2.1",
...
"devDependencies": {
"firebase-functions-test": "^0.1.6"
},
解决方案
解决了:
只是因为firebase对他们做了一个小改动,firebase-tools
0.1版本的差异足以打破仿真。
只需运行即可npm install -g firebase-tools
解决问题。
软件包版本从firebase-tools@6.9.2
...firebase-tools@6.10.0
推荐阅读
- javascript - 有没有办法在客户端行模型中使用无限滚动加载器?
- colors - CONTROL_EFFECT_MODE在小米、华为p10等部分设备上不起作用
- css - R闪亮的表格改变标题和浅色模式开关
- c# - Server.Mappath() 在远程服务器上失败
- php - Laravel API 令牌认证与 web Route::prefix('api')
- c++ - 尝试在 C++ 中打印树的内容时出现内存分配错误
- css - 在 create-react-app SassError 中导入变量:未定义的变量
- html - 具有价值而非时间的 SVG 形状变形
- python - 如何在不导入 tensorflow 的情况下从保存的模型 .h5 访问激活函数?
- c++ - C++中static关键字的定义以及静态、私有和局部变量的区别