Skip to content

1.6.5-r2: International characters in Windows username: IDE won't launch #3376

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

Closed
bjorn-wiberg opened this issue Jun 20, 2015 · 2 comments
Closed
Assignees
Labels
Type: Duplicate Another item already exists for this topic
Milestone

Comments

@bjorn-wiberg
Copy link

In Arduino 1.6.5-r2 for Windows:

If one's Windows username contains international characters, such as ö (o with two dots / umlaut) in "Björn", the Arduino IDE shows the splash screen, upto "Preparing boards...", but then no IDE pops up. Instead the program exits.

Running arduino_debug.exe reveals that it chokes in the special character "ö", yielding an "Access denied" error:

C:\Program Files (x86)\Arduino>arduino_debug.exe
Loading configuration...
Initializing packages...
Preparing boards...
java.io.FileNotFoundException: C:\Users\Bj?rn\AppData\Roaming\Arduino15\preferen
ces.txt (Åtkomst nekad) [TRANSLATION: Access denied]
at java.io.FileOutputStream.open0(Native Method)
at java.io.FileOutputStream.open(FileOutputStream.java:270)
at java.io.FileOutputStream.(FileOutputStream.java:213)
at java.io.FileOutputStream.(FileOutputStream.java:162)
at processing.app.legacy.PApplet.createWriter(PApplet.java:574)
at processing.app.PreferencesData.save(PreferencesData.java:115)
at processing.app.Base.(Base.java:343)
at processing.app.Base.guardedMain(Base.java:226)
at processing.app.Base.main(Base.java:137)
java.lang.RuntimeException: Couldn't create a writer for C:\Users\Bj?rn\AppData
Roaming\Arduino15\preferences.txt
at processing.app.legacy.PApplet.createWriter(PApplet.java:586)
at processing.app.PreferencesData.save(PreferencesData.java:115)
at processing.app.Base.(Base.java:343)
at processing.app.Base.guardedMain(Base.java:226)
at processing.app.Base.main(Base.java:137)

C:\Program Files (x86)\Arduino>
--->8--- cut --->8---

This was not so in 1.6.4 at least.

If I run it as an administrator, it works. The reason for the "access denied" message, and the reason why it works as an administrator, is that it tries to create a directory alongside the real one in C:\Users:

---8<--- cut ---8<---
C:\Users>dir
Volume in drive C is Packard Bell
Volume Serial Number is 508B-D998

Directory of C:\Users

2015-06-20 16:31

.
2015-06-20 16:31 ..
2015-04-19 15:08 Björn
2015-06-20 16:31 Bj"rn
2014-12-11 03:28 Public
0 File(s) 0 bytes
5 Dir(s) 205 368 213 504 bytes free

C:\Users>
--->8--- cut --->8---

Notice that the "ö" actually gets translated into the character ” (some typographic double quote?).

No ordinary (non-administrator) user has the right to create anything directly in C:\Users, hence it works as an administrator.

Hoping this can be fixed in some way (without changing username).

The most sensible approach would perhaps be if it could somehow get the short name version of the path in the %APPDATA% environment variable, so that...

APPDATA=C:\Users\Björn\AppData\Roaming

...would cause it to use:

APPDATA=C:\Users\BJRN~1\AppData\Roaming

...as the base for application data, and hence the preferences path would be:

C:\Users\BJRN~1\AppData\Roaming\Arduino15\preferences.txt

Best regards,
Björn

@Chris--A
Copy link
Contributor

This looks like a duplicate of the issue here: #3360

@bjorn-wiberg
Copy link
Author

Sorry, yes, my bad. This issue is a duplicate of #3360.
Closing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Duplicate Another item already exists for this topic
Projects
None yet
Development

No branches or pull requests

3 participants