classification
Title: bz2: support surrogates in filename, and bytes/bytearray filename
Type: Stage:
Components: Library (Lib), Unicode Versions: Python 3.1, Python 3.2
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: vstinner
Priority: normal Keywords: patch

Created on 2010-04-20 12:12 by vstinner, last changed 2010-04-23 11:19 by vstinner. This issue is now closed.

Files
File name Uploaded Description Edit
bz2_surrogates.patch vstinner, 2010-04-20 12:12
Messages (2)
msg103696 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2010-04-20 12:12
bz2 uses "s" format to parse the filename argument: it uses the default (unicode) encoding to encode the unicode filename to a byte string. It should use the default file system encoding instead.

It should also support surrogates in unicode filename and bytes/bytearray filenames.

Attached patch uses PyUnicode_FSConverter() to implement that.
msg104004 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2010-04-23 11:19
Commited: r80402 (py3k), r80403 (3.1).
History
Date User Action Args
2010-04-23 11:19:57vstinnersetstatus: open -> closed
resolution: fixed
messages: + msg104004
2010-04-20 12:12:56vstinnerlinkissue8242 dependencies
2010-04-20 12:12:47vstinnercreate