Title: Regression in 20.13.0 for Windows users - NPM not installed with node · Issue #52884 · nodejs/node · GitHub
Open Graph Title: Regression in 20.13.0 for Windows users - NPM not installed with node · Issue #52884 · nodejs/node
X Title: Regression in 20.13.0 for Windows users - NPM not installed with node · Issue #52884 · nodejs/node
Description: Version 20.13.0 Platform Windows Subsystem No response What steps will reproduce the bug? Install Node from chocolatey: C:\\ProgramData\\chocolatey\\bin\\choco.exe upgrade nodejs-lts -y (the output confirms the node version is 20.13.0): ...
Open Graph Description: Version 20.13.0 Platform Windows Subsystem No response What steps will reproduce the bug? Install Node from chocolatey: C:\\ProgramData\\chocolatey\\bin\\choco.exe upgrade nodejs-lts -y (the output...
X Description: Version 20.13.0 Platform Windows Subsystem No response What steps will reproduce the bug? Install Node from chocolatey: C:\\ProgramData\\chocolatey\\bin\\choco.exe upgrade nodejs-lts -y (the output...
Opengraph URL: https://github.com/nodejs/node/issues/52884
X: @github
Domain: github.com
IPv4 address: 140.82.114.4
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Regression in 20.13.0 for Windows users - NPM not installed with node","articleBody":"### Version\r\n\r\n20.13.0\r\n\r\n### Platform\r\n\r\nWindows\r\n\r\n### Subsystem\r\n\r\n_No response_\r\n\r\n### What steps will reproduce the bug?\r\n\r\nInstall Node from chocolatey:\r\n\r\n```\r\nC:\\\\ProgramData\\\\chocolatey\\\\bin\\\\choco.exe upgrade nodejs-lts -y\r\n```\r\n\r\n(the output confirms the node version is 20.13.0):\r\n```\r\nVersion 20.13.0 is available based on your source(s).\r\n```\r\n\r\nThen run an npm command:\r\n```\r\nnpm init -y\r\n```\r\n\r\nThis fails with:\r\n\r\n```\r\nError: Cannot find module 'C:\\Users\\ContainerAdministrator\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js'\r\n at Module._resolveFilename (node:internal/modules/cjs/loader:1145:15)\r\n at Module._load (node:internal/modules/cjs/loader:986:27)\r\n at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:174:12)\r\n at node:internal/main/run_main_module:28:49 {\r\n code: 'MODULE_NOT_FOUND',\r\n requireStack: []\r\n}\r\n```\r\n\r\nI was able to fix this by pinning the version to 20.12.2:\r\n\r\n```\r\nC:\\\\ProgramData\\\\chocolatey\\\\bin\\\\choco.exe upgrade nodejs-lts -y --version 20.12.2\r\n```\r\n\r\nThis only broke our Windows build, confirmed it did not affect Ubuntu. \r\n\r\n### How often does it reproduce? Is there a required condition?\r\n\r\nEvery time\r\n\r\n### What is the expected behavior? Why is that the expected behavior?\r\n\r\nNPM CLI should be available for Windows users\r\n\r\n### What do you see instead?\r\n\r\n```\r\nError: Cannot find module 'C:\\Users\\ContainerAdministrator\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js'\r\n at Module._resolveFilename (node:internal/modules/cjs/loader:1145:15)\r\n at Module._load (node:internal/modules/cjs/loader:986:27)\r\n at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:174:12)\r\n at node:internal/main/run_main_module:28:49 {\r\n code: 'MODULE_NOT_FOUND',\r\n requireStack: []\r\n}\r\n```\r\n\r\n### Additional information\r\n\r\n_No response_","author":{"url":"https://github.com/comcalvi","@type":"Person","name":"comcalvi"},"datePublished":"2024-05-08T05:02:25Z","url":"https://github.com/nodejs/node/issues/52884"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:4113e9f5-df8a-f197-874d-8373001e87ac |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8BB2:2DC49E:914FD7:B8F2B9:6B03645C |
| html-safe-nonce | a0ddeea158c64359bd8d935d923afd8520204b6b3f4d64d79a37ea55ff956c41 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4QkIyOjJEQzQ5RTo5MTRGRDc6QjhGMkI5OjZCMDM2NDVDIiwidmlzaXRvcl9pZCI6IjcwNDY2NzE0Mjg5NDI1MjE0MzYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | ded474ee2f1b6b4f117a83af28f39ccc18b2719fbf2049b2f8c79711652a146b |
| hovercard-subject-tag | issue:2284684435 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/52884/issue_layout |
| twitter:image | https://opengraph.githubassets.com/5422b71dfb5b1040d68e25b1eb5d0197a241c1cd55fc079d3d8ac7a243df6b84/nodejs/node/issues/52884 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/5422b71dfb5b1040d68e25b1eb5d0197a241c1cd55fc079d3d8ac7a243df6b84/nodejs/node/issues/52884 |
| og:image:alt | Version 20.13.0 Platform Windows Subsystem No response What steps will reproduce the bug? Install Node from chocolatey: C:\\ProgramData\\chocolatey\\bin\\choco.exe upgrade nodejs-lts -y (the output... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | comcalvi |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width