gpt4 book ai didi

linux - 通过 nvm 升级 Node 后 Node 调试中断

转载 作者:太空宇宙 更新时间:2023-11-04 12:52:46 30 4
gpt4 key购买 nike

我刚刚将 Node 从 v0.12.2 升级到 v5.10.1,node-debug 对我来说似乎坏了。

当我运行时:

node-debug bin/www

我在 Chrome 中收到以下错误:

Error: Cannot find module '/usr/local/lib/node_modules/node-inspector/node_modules/v8-debug/build/debug/v0.4.6/node-v47-linux-x64/debug.node'

我没有 node-v47-linux-x64 目录,但我有一个 node-v14-linux-x64 目录

node -v
v5.10.1

npm -v
3.8.3

关于如何解决这个问题有什么建议吗?

最佳答案

清除 npm 缓存并重新安装模块似乎有效。我在全局重新安装了一些模块( Node 检查器...)

npm cache clear
npm install

问题似乎出在我使用 nvm 上。

(注意,全局模块需要在每个 Node 版本中重新安装,包括您的系统版本,否则它们可能无法正常工作)

关于linux - 通过 nvm 升级 Node 后 Node 调试中断,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36635403/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com