GNOME Bugzilla – Bug 709058
Meld does not run if the user profile contains Unicode characters.
Last modified: 2013-10-18 08:14:24 UTC
If you run meld with in an account where the username has Unicode characters it breaks when it tries to create the preferences directory. I have a fix that uses winreg (I will attach it later)
Created attachment 256054 [details] [review] fixes the issue This fix means that Unicode usernames will not be truncated and thus break the creation of the directory for preferences.
The patch will require a little work to go straight up, as it's not valid for linux (the change to recent.py will break)
Shall I change it into an if windows or if path does not exist then try using Unicode path?
Created attachment 256156 [details] [review] Corrected Patch Ignore the previous patch. This one should work on Linux as well.
Thanks for chasing this down. I'm willing to apply that patch if necessary, but I have to admit that I'd rather not be using _winreg. Could you give an example of a username where this breaks, so that I can test? Also, when it breaks, what is the repr() of the directory that the current code is trying to find? I'm wondering if we just need to decode from the filesystem encoding or something. The glib docs for g_get_user_data_dir() and friends indicate that this *should* be returning UTF8, so we might just be missing that decode().
I just used a username like 你好 and this broke it. I'll reply to the rest when I get home.
Review of attachment 256156 [details] [review]: pretty bad.
Okay so I just tested and all that's needed is .decode('utf-8')
Created attachment 257062 [details] [review] Decode patch Could you please test this patch out and let me know how it goes? It will unfortunately move user preferences from roaming to local appdata, but I think it's the sanest available way to actually work consistently.
Review of attachment 257062 [details] [review]: Looks fine to me.
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report.