[issue18171] os.path.expanduser does not use the system encoding

2013-06-09 Thread Pascal Garcia
Pascal Garcia added the comment: Sorry for this error. Thanks for the solution. Here is the code as I modify it. wrkdir= os.path.expanduser("~"+os.sep) loc = locale.getdefaultlocale() if loc[1]: encoding = loc[1]

[issue18171] os.path.expanduser does not use the system encoding

2013-06-09 Thread Pascal Garcia
Pascal Garcia added the comment: Here are 2 logs one with the default site.py forcing defaultencoding to ascii, and the other to utf8. You can see that the home dir includes accents : Pépé Not an insult to anybody but this stupid computer :) When I force using the locale.getdefaultlocale() as

[issue18171] os.path.expanduser does not use the system encoding

2013-06-09 Thread Pascal Garcia
New submission from Pascal Garcia: The name of the user contains accents under windows. This error occurs when using the function. expaduser("~") UnicodeDecodeError: 'ascii' codec can't decode byte 0xe9 in position 10: ordinal not in range(128) ascii i