You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bz2: support surrogates in filename, and bytes/bytearray filename #52714
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2010-04-23.11:19:57.868>created_at=<Date2010-04-20.12:12:47.849>labels= ['library', 'expert-unicode']
title='bz2: support surrogates in filename, and bytes/bytearray filename'updated_at=<Date2010-04-23.11:19:57.866>user='https://github.com/vstinner'
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.
Activity
vstinner commentedon Apr 20, 2010
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.
vstinner commentedon Apr 23, 2010
Commited: r80402 (py3k), r80403 (3.1).