This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: bz2: support surrogates in filename, and bytes/bytearray filename
Type: Stage:
Components: Library (Lib), Unicode Versions: Python 3.1, Python 3.2
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 2022-04-11 14:57 by admin. This issue is now closed.

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).
Date User Action Args
2022-04-11 14:57:00adminsetgithub: 52714
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