无法安装谷歌云功能模拟器

问题描述 投票:0回答:1

我试图将firebase更新到最新版本并遇到错误。这指向函数模拟器有一个问题:

$ npm install @google-cloud/functions-emulator
npm ERR! Unexpected end of JSON input while parsing near '..."retry-request":"^4.0'

最近在firebase上更新后会发生这种情况。我做错了什么,或者我应该报告这个错误?

尝试了多种解决方案,包括完全卸载npm,node甚至vsc。更新npm,尝试专门安装云函数模拟器...在某些依赖项文件中始终存在相同的错误。

这是error log

88 error Unexpected end of JSON input while parsing near '..."retry-request":"^4.0'

我只是想将firebase更新到最新版本。现在一切都坏了:D

任何帮助深表感谢。

firebase npm google-cloud-platform google-cloud-functions
1个回答
1
投票

由于文件下载损坏(尝试在火车上安装firebase更新)而发生错误。

解决:

npm cache clean --force

然后重新安装包。

© www.soinside.com 2019 - 2024. All rights reserved.