-
-
Notifications
You must be signed in to change notification settings - Fork 105
somethig wrong with npx Command failed: C:\“Program Files”\nodejs\node.exe #110
Comments
Just ran into this, too. Looks like |
Running into the same thing here:
|
Might be worth bisecting this against previous versions of |
I'm pretty sure this is happening because different Windows shells require different types of path escapes -- on Windows, npx uses CMD-style escapes, for example. |
I use |
Got the same issue, with Git Bash on Win10. |
This issue should be fixed in the latest npx (at least it was for me), which is not included in the latest nodejs installer. You can manually update/install |
@rossipedia you mean it's fixed on master, rather than 9.6.0? (there is no tag newer than that, and that's the latest version npm knows about) |
Hmmmm |
Also still having this issue on Behavior hasn't changed on |
When I looked into it, it seems as though path quoting is performed incorrectly on Windows. Instead of quoting each path element (eg: |
@noahleigh If you are using Node 8.4.0 or newer, it falls to installed npx, which is npx 9.2.1. I just deleted the npx files in the node folder for this to work. |
tbh I probably need help here. I've spent time messing around with different escape methods, and they seem to vary by situation :\ |
@zkat latest version seems to run fine. Did you find bugs in Windows? Or with the fix for Windows something else got broken? |
@zkat I'll try my hand at a PR here this weekend, I think I remember where the problematic method is |
@michaeljota I deleted
Why would node fail to use the updated version even after |
Because, as it does when updating |
A bit more on that: When nodejs is installed, the installation folder (eg: However, your npm installation folder's bin directory Now here's the part where it breaks: in Windows, to get the final I've personally fixed it by removing |
@rossipedia Why does the nodejs installer put |
I think it does now because of backwards compatibility only. It has been
broken since day one. The thing is that if the instalation append the app
data folder route before the program route it would be fine.
El sept. 16, 2017 6:12, "Noah Leigh" <notifications@github.com> escribió:
… @rossipedia <https://github.com/rossipedia> Why does the nodejs installer
put npm stuff in the Program Files folder if the "real" and updated
versions live in App Data? Why not just keep the executables in there
exclusively?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#110 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AKBWAAr8CRz2WzsvAdOXesD8wSx8hsW6ks5si58KgaJpZM4O11_x>
.
|
Relevant nodejs issue: nodejs/node#15095 |
@noahleigh workaround to manually clean out |
Deleting the files from Program Files, as @noahleigh suggested, and updating to 9.6.0 resolved the issue for me. |
I think it is good follow Deleting the files from Program Files, as @noahleigh suggested, and updating to 9.6.0 resolved the issue for me also. |
|
@rossipedia your solution works perfectly |
I got a similar error in an npm script and fixed by using the 8.3 ntfs filesystem shortname. e.g.: "c:\PROGRA~1\7-Zip\7z.exe" |
my npx always show this error
Command failed: C:\"Program Files"\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js config get cache --parseable module.js:487
The text was updated successfully, but these errors were encountered: