-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Npm publish failed, file not found #7853
Comments
Same issue on Mac and Linux (pipeline on GitHub Actions), both at node 23. |
This might be related to node js 23.. I am able to reproduce similer error with node 23 whereas node 22.9.0 with npm 10.9.0 works as expected. ~/workarea/rep/test/test2 $ nvm use 22.9
Now using node v22.9.0 (npm v10.9.0)
~/workarea/rep/test/test2 $ npm publish --registry=http://localhost:4873
npm notice
npm notice 📦 milan-test-publish@3.0.0
npm notice Tarball Contents
npm notice 19B dist/index.js
npm notice 57B package.json
npm notice Tarball Details
npm notice name: milan-test-publish
npm notice version: 3.0.0
npm notice filename: milan-test-publish-3.0.0.tgz
npm notice package size: 198 B
npm notice unpacked size: 76 B
npm notice shasum: 269937c292086c079b8d330da32be9130a8a3d47
npm notice integrity: sha512-7Rjh1V9nWZRNl[...]dJTlpDJd6KmDA==
npm notice total files: 2
npm notice
npm notice Publishing to http://localhost:4873/ with tag latest and default access
+ milan-test-publish@3.0.0
~/workarea/rep/test/test2 $ nvm use 23
Now using node v23.0.0 (npm v10.9.0)
~/workarea/rep/test/test2 $ npm version minor
v3.1.0
~/workarea/rep/test/test2 $ npm publish --registry=http://localhost:4873
(node:8975) ExperimentalWarning: Support for loading ES Module in require() is an experimental feature and might change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
npm warn tarball tarball data for file:/Users/milaninfy/workarea/rep/test/test2/ (null) seems to be corrupted. Trying again.
npm warn tarball tarball data for file:/Users/milaninfy/workarea/rep/test/test2/ (null) seems to be corrupted. Trying again.
npm error code ENOENT
npm error syscall lstat
npm error path /Users/milaninfy/workarea/rep/test/test2/ist/index.js
npm error errno -2
npm error enoent ENOENT: no such file or directory, lstat '/Users/milaninfy/workarea/rep/test/test2/ist/index.js'
npm error enoent This is related to npm not being able to find a file.
npm error enoent
npm error A complete log of this run can be found in: /Users/milaninfy/.npm/_logs/2024-10-18T13_08_38_125Z-debug-0.log
|
This issue might be related to nodejs/node#55410 |
Node 22.9.0 / 22.10.0 works, so it's related to node 23.0.0 |
yes, works for me. |
Closing this as it's not npm-cli issue. |
Bug resolved, tested with nightly/v24.0.0-nightly20241022e4ca097f56 |
I can confirm this is fixed in Node v23.1.0, so there is no need to use nightly anymore. |
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
Since the update, when i trying to publish my package to a private repository (gitlab package registry) i got an error.
I tried with 3 environements :
The path seems incorrect because the file path is : C:\User\workspace\project\README.md
There is a new warning with v10.9.0 but it's not related to the issue i think :
(node:48612) ExperimentalWarning: Support for loading ES Module in require() is an experimental feature and might change at any time
Expected Behavior
There are no errors with previous version : 10.8.3 & node 22.9.0 and the package is published to our private repository.
Steps To Reproduce
Build a librairy and try to publish it on a repository, our is a gitlab package registry.
Environment
The text was updated successfully, but these errors were encountered: