错误:发生意外错误。尝试部署我的程序时

时间:2020-06-10 11:01:57

标签: firebase google-cloud-firestore firebase-hosting firebase-cli

我正在尝试部署一个有角度的程序,并且在尝试部署时不断出现上述错误。这是firebase-debug.log的内容。

我正在使用命令firebase deploy --only hosting:viewer。我在Windows计算机上,常规的firebase deployng deploy命令也不起作用,它们给出了:

无法读取未定义的属性“ deploys”

[debug] [2020-06-10T10:35:50.076Z] ----------------------------------------------------------------------
[debug] [2020-06-10T10:35:50.132Z] Command:       C:\Program Files\nodejs\node.exe C:\Users\tyrel\AppData\Roaming\npm\node_modules\firebase-tools\lib\bin\firebase.js deploy --only hosting:viewer
[debug] [2020-06-10T10:35:50.132Z] CLI Version:   6.6.0
[debug] [2020-06-10T10:35:50.132Z] Platform:      win32
[debug] [2020-06-10T10:35:50.133Z] Node Version:  v12.16.3
[debug] [2020-06-10T10:35:50.135Z] Time:          Wed Jun 10 2020 06:35:50 GMT-0400 (Eastern Daylight Time)
[debug] [2020-06-10T10:35:50.136Z] ----------------------------------------------------------------------
[debug] 
[debug] [2020-06-10T10:35:50.234Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2020-06-10T10:35:50.235Z] > authorizing via signed-in user
[debug] [2020-06-10T10:35:50.236Z] [iam] checking project glasser-ffb7a for permissions ["firebase.projects.get","firebasehosting.sites.update"]
[debug] [2020-06-10T10:35:50.249Z] >>> HTTP REQUEST POST https://cloudresourcemanager.googleapis.com/v1/projects/glasser-ffb7a:testIamPermissions  

[debug] [2020-06-10T10:35:51.061Z] <<< HTTP RESPONSE 200
[debug] [2020-06-10T10:35:51.065Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects/glasser-ffb7a  

[debug] [2020-06-10T10:35:52.182Z] <<< HTTP RESPONSE 200
[info] 
[info] === Deploying to 'glasser-ffb7a'...
[info] 
[info] i  deploying hosting
[info] 
[info] +  Deploy complete!
[info] 
[info] Project Console: https://console.firebase.google.com/project/glasser-ffb7a/overview
[debug] [2020-06-10T10:35:52.387Z] TypeError: Cannot read property 'deploys' of undefined
    at C:\Users\tyrel\AppData\Roaming\npm\node_modules\firebase-tools\lib\deploy\index.js:88:36
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
[error] 
[error] Error: An unexpected error has occurred.
[debug] [2020-06-10T10:37:35.594Z] ----------------------------------------------------------------------
[debug] [2020-06-10T10:37:35.664Z] Command:       C:\Program Files\nodejs\node.exe C:\Users\tyrel\AppData\Roaming\npm\node_modules\firebase-tools\lib\bin\firebase.js deploy --only hosting:viewer
[debug] [2020-06-10T10:37:35.664Z] CLI Version:   6.6.0
[debug] [2020-06-10T10:37:35.664Z] Platform:      win32
[debug] [2020-06-10T10:37:35.664Z] Node Version:  v12.16.3
[debug] [2020-06-10T10:37:35.666Z] Time:          Wed Jun 10 2020 06:37:35 GMT-0400 (Eastern Daylight Time)
[debug] [2020-06-10T10:37:35.666Z] ----------------------------------------------------------------------
[debug] 
[debug] [2020-06-10T10:37:35.691Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2020-06-10T10:37:35.692Z] > authorizing via signed-in user
[debug] [2020-06-10T10:37:35.692Z] [iam] checking project glasser-ffb7a for permissions ["firebase.projects.get","firebasehosting.sites.update"]
[debug] [2020-06-10T10:37:35.695Z] >>> HTTP REQUEST POST https://cloudresourcemanager.googleapis.com/v1/projects/glasser-ffb7a:testIamPermissions  

[debug] [2020-06-10T10:37:36.057Z] <<< HTTP RESPONSE 200
[debug] [2020-06-10T10:37:36.061Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects/glasser-ffb7a  

[debug] [2020-06-10T10:37:36.272Z] <<< HTTP RESPONSE 200
[info] 
[info] === Deploying to 'glasser-ffb7a'...
[info] 
[info] i  deploying hosting
[info] 
[info] +  Deploy complete!
[info] 
[info] Project Console: https://console.firebase.google.com/project/glasser-ffb7a/overview
[debug] [2020-06-10T10:37:36.418Z] TypeError: Cannot read property 'deploys' of undefined
    at C:\Users\tyrel\AppData\Roaming\npm\node_modules\firebase-tools\lib\deploy\index.js:88:36
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
[error] 
[error] Error: An unexpected error has occurred.
[debug] [2020-06-10T10:47:21.266Z] ----------------------------------------------------------------------
[debug] [2020-06-10T10:47:21.272Z] Command:       C:\Program Files\nodejs\node.exe C:\Users\tyrel\AppData\Roaming\npm\node_modules\firebase-tools\lib\bin\firebase.js deploy --only hosting:viewer
[debug] [2020-06-10T10:47:21.273Z] CLI Version:   8.4.2
[debug] [2020-06-10T10:47:21.273Z] Platform:      win32
[debug] [2020-06-10T10:47:21.273Z] Node Version:  v12.16.3
[debug] [2020-06-10T10:47:21.278Z] Time:          Wed Jun 10 2020 06:47:21 GMT-0400 (Eastern Daylight Time)
[debug] [2020-06-10T10:47:21.279Z] ----------------------------------------------------------------------
[debug] [2020-06-10T10:47:21.279Z] 
[debug] [2020-06-10T10:47:21.318Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2020-06-10T10:47:21.319Z] > authorizing via signed-in user
[debug] [2020-06-10T10:47:21.320Z] [iam] checking project glasser-ffb7a for permissions ["firebase.projects.get","firebasehosting.sites.update"]
[debug] [2020-06-10T10:47:21.325Z] >>> HTTP REQUEST POST https://cloudresourcemanager.googleapis.com/v1/projects/glasser-ffb7a:testIamPermissions  
 {"permissions":["firebase.projects.get","firebasehosting.sites.update"]}
[debug] [2020-06-10T10:47:21.741Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Wed, 10 Jun 2020 10:47:23 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","server-timing":"gfet4t7; dur=130","alt-svc":"h3-27=\":443\"; ma=2592000,h3-25=\":443\"; ma=2592000,h3-T050=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q049=\":443\"; ma=2592000,h3-Q048=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[debug] [2020-06-10T10:47:21.745Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects/glasser-ffb7a  

[debug] [2020-06-10T10:47:22.177Z] <<< HTTP RESPONSE 200 {"content-type":"application/json; charset=UTF-8","vary":"X-Origin, Referer, Origin,Accept-Encoding","date":"Wed, 10 Jun 2020 10:47:23 GMT","server":"ESF","cache-control":"private","x-xss-protection":"0","x-frame-options":"SAMEORIGIN","x-content-type-options":"nosniff","alt-svc":"h3-27=\":443\"; ma=2592000,h3-25=\":443\"; ma=2592000,h3-T050=\":443\"; ma=2592000,h3-Q050=\":443\"; ma=2592000,h3-Q049=\":443\"; ma=2592000,h3-Q048=\":443\"; ma=2592000,h3-Q046=\":443\"; ma=2592000,h3-Q043=\":443\"; ma=2592000,quic=\":443\"; ma=2592000; v=\"46,43\"","accept-ranges":"none","transfer-encoding":"chunked"}
[info] 
[info] === Deploying to 'glasser-ffb7a'...
[info] 
[info] i  deploying hosting 
[info] 
[info] +  Deploy complete! 
[info] 
[info] Project Console: https://console.firebase.google.com/project/glasser-ffb7a/overview
[debug] [2020-06-10T10:47:22.365Z] TypeError: Cannot read property 'deploys' of undefined
    at C:\Users\tyrel\AppData\Roaming\npm\node_modules\firebase-tools\lib\deploy\index.js:84:36
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
[error] 
[error] Error: An unexpected error has occurred.

edit:我知道这里有一些针对此问题的修复程序,但是我尝试过的修复程序都没有奏效。我现在找不到再尝试了。 github修复无效,我尝试过的StackOverflow解决方案也没有。

0 个答案:

没有答案