Issue1520

classification
Title: os.listdir doesn't return unicode when requested
Type: crash Severity: normal
Components: Core Versions: 2.5.0
Milestone:
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: pjenvey, ssteiner
Priority: Keywords:

Created on 2009-12-08.13:22:11 by ssteiner, last changed 2010-04-11.03:18:47 by pjenvey.

Messages
msg5361 (view) Author: simon steiner (ssteiner) Date: 2009-12-08.13:22:10
import os

os.mkdir('test_unicode')
open(u'test_unicode/test_\u00e9.txt', 'w').close()

for dirpath, subdirs, files in os.walk(unicode(r'test_unicode')):
    print dirpath
    print subdirs
    print files
msg5366 (view) Author: simon steiner (ssteiner) Date: 2009-12-09.11:53:42
in os.py

- return [asPyString(entry) for entry in l]
+ return l
msg5374 (view) Author: simon steiner (ssteiner) Date: 2009-12-10.13:02:06
should be

- return [asPyString(entry) for entry in l]
+ return [entry for entry in l]
msg5658 (view) Author: Philip Jenvey (pjenvey) Date: 2010-04-11.03:18:47
fixed in r7016
History
Date User Action Args
2010-04-11 03:18:47pjenveysetstatus: open -> closed
resolution: fixed
messages: + msg5658
nosy: + pjenvey
title: UnicodeDecodeError -> os.listdir doesn't return unicode when requested
2009-12-10 13:02:06ssteinersetmessages: + msg5374
2009-12-09 11:53:42ssteinersetmessages: + msg5366
2009-12-08 13:22:11ssteinercreate