-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
"nvm could not be found" when user name has umlaut or non-ascii character #726
Comments
Regarding the workaround: it's the "root" setting that needs correcting. |
Which version of NVM4W are you using? There appears to be an issue in older versions of Go that misinterpret umlauts and other western European characters. I'm unclear whether these issues are fully resolved in more recent versions of Go. |
I was using the latest version 1.1.9. |
I can't find the installer version but it was created on December 15 at 20:11:50. |
Thanks, v1.1.9 was created with Go 1.17, which is the latest stable release of Go. I'm unsure how to troubleshoot this at the moment since I do not have access to a German version of Windows. There is also a possibility this hasn't been fixed (or a reversion happened). I will look into this to the best of my ability, but I wouldn't count on an immediate resolution given the circumstance. |
+1 from me - same issue seems to have occurred with a colleague with a Ç in his last name trying to install v1.1.9. We have not attempted older versions. The version of Windows does not seem to be the issue (I believe he too is running on an English install) - it seems to be merely the path to the install location, in this case the username part. If I understand correctly, this should be reproducable by creating a new user (either "online" / MS account, or offline) with one or more "special" characters like those mentioned in the username. But I could be mistaken =) |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
Not stale AFAIK. (Looks like #744 is a recent duplicate.) |
I didn't have this problem until after I upgraded to Windows 11 and upgraded NVM. It worked fine before upgrading to 1.1.9 but downgrading now doesn't help. I got around this by opening |
@karl-sjogren thanks for sharing. It could be the installer, but it could also be Windows 11 not respecting the file encoding (which should be UTF8 by default). It's a little difficult to tell while Windows 11 keeps receiving updates. It sounds like encoding is the problem regardless of whether the content is read from the settings file or displayed as an error message. Go 1.18 was just released and it looks like there may be a fix. I'll try building the next maintenance release on this to see if it resolves @heneds original issue. As for the installer, it hasn't changed in years (and works on American English editions), so I suspect something is going on with the Windows 11 encoding. Regardless, I will look into this when I get a chance to build the next update. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
This issue was closed because it has been stalled for 7 days with no activity. |
Having this same issue on Windows 11 and NVM 1.1.9 installed from Winget |
This wasn't supposed to be closed by the bot. |
I just experienced this on a newly installed nvm v1.1.9, Windows 10 pro (10.0.19044). Opened nvm\settings.txt and it was saved as ANSI encoding. Converting it to UTF8 as suggested by Karl fixed the issue. Just wanted to give a second report of this as it happened on Windows 10 too. |
Can't we add the https://stackoverflow.com/questions/16598785/save-text-file-in-utf-8-encoding-using-cmd-exe |
I only realized after @noysom 's message that I never mentioned that, afaik, my colleague who has this issue is also running on Windows 10 instead of 11. We eventually worked around it by installing NVM in a different location (read; not the user directory, and thus avoiding having the non-ascii character in his username in the install path), as mentioned before. [edit:] ... by 'before' I meant I could swear it was mentioned by someone else in this thread as a workaround. It seems I was mistaken as I can't find it. It was probably in one of the duplicate issue threads instead. So if anyone wanted to know another workaround that the "change encoding" one mentioned in here, there you go, just know I don't deserve the credit for it ;) [/edit] |
Same issue on Windows 10 Pro with a non-ascii username (
EDIT:Found a workaroundChange the install folder to a filepath without non-ascii letters in it. I installed it to EDIT 2:I recommend changing your windows username to ASCII-only lettersBecause this is a common issue with a lot of other apps as well, I opted to change my windows profile name instead. I recommend this for anyone who's reasonably tech-savvy, understand the risk and are willing to spend some time (1-2hrs) changing the username to save you from a lot of trouble down the line. DISCLAIMER! That said, here's some resources I used:
|
Just ran into this as well and had to change the installation directory. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
This issue was closed because it has been stalled for 7 days with no activity. |
Bot keeps closing this. |
Also happens with nvm |
This issue also happens if the directory contains a space, however the workaround does not work. |
It has also happened to me on Windows 11 Pro, my username contains a Adding it to the Documentation would be nice. I can do it if you want |
Same for me Windows 11 with Polish non ascii signs workaround with changing settings.txt to urf-8 encoding helped #726 (comment) |
Happened to me today. This workaround fixed it.
|
Issue:
After a fresh installation of nvm the application does not work but fails with the error message
"C:\Users_USERNAME_\AppData\Roaming\nvm could not be found or does not exist. Exiting."
This happens when USERNAME contains a non-ascii character. In the error message these characters are replaced with �.
How To Reproduce:
Expected Behavior:
Expecting to see a list of node versions.
Workaround:
It works properly if you correct the path in settings.txt (while keeping the UTF-8 encoding)
Desktop:
Windows 11
The text was updated successfully, but these errors were encountered: