【问题标题】:Firebase function status failedFirebase 功能状态失败
【发布时间】:2019-10-06 12:54:46
【问题描述】:
D:\work\ocr\receiptWeb\functions>functions list
┌────────┬────────┬─────────┬─────────────────────────────────────────────────────────────────┐    
│ Status │ Name   │ Trigger │ Resource                                                        │    
├────────┼────────┼─────────┼─────────────────────────────────────────────────────────────────┤    
│ FAILED │ upload │ HTTP    │ http://localhost:8010/invoice-manager-251609/us-central1/upload │    
├────────┼────────┼─────────┼─────────────────────────────────────────────────────────────────┤    
│ FAILED │ tst    │ HTTP    │ http://localhost:8010/invoice-manager-251609/us-central1/tst    │    
├────────┼────────┼─────────┼─────────────────────────────────────────────────────────────────┤    
│ FAILED │ tst1   │ HTTP    │ http://localhost:8010/invoice-manager-251609/us-central1/tst1   │    
└────────┴────────┴─────────┴─────────────────────────────────────────────────────────────────┘    



D:\work\ocr\receiptWeb\functions>functions describe tst1
┌────────────┬───────────────────────────────────────────────────────────────────┐
│ Property   │ Value                                                             │
├────────────┼───────────────────────────────────────────────────────────────────┤
│ Name       │ tst1                                                              │
├────────────┼───────────────────────────────────────────────────────────────────┤
│ Trigger    │ HTTP                                                              │
├────────────┼───────────────────────────────────────────────────────────────────┤
│ Resource   │ http://localhost:8010/invoice-manager-251609/us-central1/tst1     │
├────────────┼───────────────────────────────────────────────────────────────────┤
│ Timeout    │ 60 seconds                                                        │
├────────────┼───────────────────────────────────────────────────────────────────┤
│ Local path │ D:\work\ocr\receiptWeb\functions                                  │
├────────────┼───────────────────────────────────────────────────────────────────┤
│ Archive    │ file://C:\Users\USER\AppData\Local\Temp\tmp-12096kv8vKcUEnCAt.zip │
└────────────┴───────────────────────────────────────────────────────────────────┘

当我转到网址时,我得到了

Function worker crashed with exit code: 1\nundefinedWarning, estimating Firebase Config based on GCLOUD_PROJECT. Initializing firebase-admin may fail[2019-10-06T12:57:02.376Z] @firebase/database: FIREBASE FATAL ERROR: Cannot parse Firebase url. Please use https://<YOUR FIREBASE>.firebaseio.com

我做到了

set FIREBASE_CONFIG={"projectId":"invoice-manager-251609","appId":"1:127001043239:web:e3c996dc4dab60b7c94902","databaseURL":"https://invoice-manager-251609.firebaseio.com","storageBucket":"invoice-manager-251609.appspot.com","locationId":"europe-west","apiKey":"AIzaSyCaV3vpQaEMUPjz9CftkYdp888l7cLy8Gw","authDomain":"invoice-manager-251609.firebaseapp.com","messagingSenderId":"127001043239"}

而且网址是正确的 如何获取有关 FAILED 状态原因的更多信息?

【问题讨论】:

    标签: firebase firebase-cli firebase-tools


    【解决方案1】:

    当云函数遇到错误时,它通常会记录详细信息。可以通过$ functions logs read查看本地模拟器的日志文件。

    【讨论】:

      猜你喜欢
      • 2021-12-29
      • 1970-01-01
      • 2020-11-13
      • 1970-01-01
      • 1970-01-01
      • 2011-07-23
      • 2020-05-23
      • 2021-01-23
      • 2023-04-01
      相关资源
      最近更新 更多