New submission from Campbell Barton <ideasma...@gmail.com>: # create this path. # it could be made by any application but including this line # so encoding is not confused. # c:\äöü __import__("os").mkdir(b'c:\\\xe4\xf6\xfc')
# Now create a new script and save in the newly created dir c:\äöü\test.py # In c:\äöü\test.py add the following line __import__("os").listdir(os.path.dirname(__file__)) # Now run the script from the command line using its absolute path. c:\Python31\python.exe c:\äöü\test.py --- This gives an error. Traceback (most recent call last): File "m:\\xc3\xa4\xc3\xb6\xc3¼\test.py", line 2, in <module> WindowsError: [Error 3] The system cannot find the path specified: 'm:\\\xc3\xa4\xc3\xb6\xc3¼\\*.*' This is a bug because a script should be able to inspect the path where it is located. ---------- components: Interpreter Core messages: 123063 nosy: ideasman42 priority: normal severity: normal status: open title: __file__ not usable, with certain paths on windows XP. type: behavior versions: Python 3.1 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue10603> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com