Can't execute/run node-pre-gyp successfully. Having this error.
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.2k
- Forks
- 271
- Avg merge
- 23h 40m
- Merged PRs (30d)
- 2
Description
```
D:\JavaScript\2022\test\node_modules\.bin>node-pre-gyp
node:internal/fs/utils:344
throw err;
^
Error: ENOENT: no such file or directory, open './package.json'
at Object.openSync (node:fs:585:3)
at Object.readFileSync (node:fs:453:35)
at Run.parseOpts [as parseArgv] (D:\JavaScript\2022\test\node_modules\@mapbox\node-pre-gyp\lib\node-pre-gyp.js:181:37)
at new Run (D:\JavaScript\2022\test\node_modules\@mapbox\node-pre-gyp\lib\node-pre-gyp.js:90:8)
at Object. (D:\JavaScript\2022\test\node_modules\@mapbox\node-pre-gyp\lib\main.js:16:14)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19) {
errno: -4058,
syscall: 'open',
code: 'ENOENT',
path: './package.json'
}
D:\JavaScript\2022\test\node_modules\.bin>
```
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the Windows command shown in the issue from the project directory, then inspect lib/node-pre-gyp.js around parseOpts and the attempted read of ./package.json. Determine the expected working-directory or invocation behavior and verify that the command no longer fails with ENOENT.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100