redhat-developer / redhat-developer/vscode-java
vscode-java doesn't build on Mac with Node 14
未关闭
还没有人认领这个 Issue。
build/infra
- 主要语言
- TypeScript
- 星标
- 2.3k
- 派生
- 546
- 平均合并
- 20 小时 1 分钟
- 30 天内合并 PR
- 11
描述
Using the same node 14.19.1 as Jenkins, the project fails to build on my Mac.
❯ node --version
v14.19.1
❯ npm ci
npm WARN prepare removing existing node_modules/ before installation
> fsevents@1.2.13 install /Users/fbricon/Dev/projects/vscode-java/node_modules/glob-watcher/node_modules/fsevents
> node install.js
internal/modules/cjs/loader.js:905
throw err;
^
Error: Cannot find module 'nan'
Require stack:
- /Users/fbricon/Dev/projects/vscode-java/node_modules/glob-watcher/node_modules/fsevents/[eval]
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
at Function.Module._load (internal/modules/cjs/loader.js:746:27)
at Module.require (internal/modules/cjs/loader.js:974:19)
at require (internal/modules/cjs/helpers.js:101:18)
at [eval]:1:1
at Script.runInThisContext (vm.js:134:12)
at Object.runInThisContext (vm.js:310:38)
at internal/process/execution.js:81:19
at [eval]-wrapper:6:22
at evalScript (internal/process/execution.js:80:60) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'/Users/fbricon/Dev/projects/vscode-java/node_modules/glob-watcher/node_modules/fsevents/[eval]'
]
}
gyp: Call to 'node -e "require('nan')"' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/Users/fbricon/.nvm/versions/node/v14.19.1/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:351:16)
gyp ERR! stack at ChildProcess.emit (events.js:400:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:282:12)
gyp ERR! System Darwin 21.6.0
gyp ERR! command "/Users/fbricon/.nvm/versions/node/v14.19.1/bin/node" "/Users/fbricon/.nvm/versions/node/v14.19.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/fbricon/Dev/projects/vscode-java/node_modules/glob-watcher/node_modules/fsevents
gyp ERR! node -v v14.19.1
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
added 875 packages in 13.275s
It builds when I start using Node 16
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
未指定源文件或测试。使用 npm ci 在 macOS 上通过 Node 14.19.1 重现该故障,然后检查涉及缺失 nan 模块的 fsevents 安装错误。当项目使用 Jenkins 所用的 Node 版本成功安装并构建时,即表示完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- node.js, typescript
- 领域
- build-system
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 30/100