There is a closed ticket talking about this, but it does not seem to be fixed for me.
I submitted a new comment on that ticket, and it doesn't show up. I think this won't change until some moderator pays attention to it. So I post my comment here. This problem seems not to be fixed for me. The error message in http://www.pyinstaller.org/ticket/298#comment:28 > Traceback (most recent call last): > File "C:/Users/Aaron/Dropbox/programming/test/OStest/pyinstallertest.py", > line 4, in <module> > print win32api.GetShortPathName(chinese_path) > pywintypes.error: (123, 'GetShortPathNameW', > '\xc0\xc9\xae\xd7\xa6W\xba\xd9\xa1B\xa5\xd8\xbf\xfd\xa6W\xba\xd9\xa9\xce\xba\xcf\xba\xd0\xb0\xcf\xbc\xd0\xc5\xd2\xbby\xaak\xbf\xf9\xbb~\xa1C') > > is “檔案名稱、目錄名稱或磁碟區標籤語法錯誤。” in chinese. It means, *the file name, the dir name or the drive name has syntax error. *Because the '\' in > chinese_path = u"D:\test\新增資料夾" should be escaped. My test script was > #coding:gbk > > import win32api > > chinese_path = u"D:\\新建文件夹" > > print(win32api.GetShortPathName(chinese_path)) > > (you need to create a dir named "新建文件夹", or you'll get a error 2.) It showed > D:\新建文~1 So I think the GetShortPathNameW can handle Chinese chars correctly. Any suggestions? Thanks, Hanfei -- You received this message because you are subscribed to the Google Groups "PyInstaller" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/pyinstaller. For more options, visit https://groups.google.com/groups/opt_out.
