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.

Author koffie
Recipients John Helour, koffie, lemburg, loewis, mdk, serhiy.storchaka, vstinner, xiang.zhang
Date 2021-06-29.13:12:35
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1624972355.3.0.149581554855.issue24339@roundup.psfhosted.org>
In-reply-to
Content
The route via gencodec or more generally via charmap_encode and charmap_decode seems to be one that is not possible without some low level CPython code adjustments. The reason for this is that charmap_encode and charmap_decode only seem to support mappings where a single encoded byte corresponds to multiple unicode points.

However iso6937 is a mixed length encoding, meaning in this specific case that unicode characters sometimes need to be encoded as a single byte and sometimes with two bytes.

For example chr(0x00c0) should be encoded as b'\xc1' + b'A'.
History
Date User Action Args
2021-06-29 13:12:35koffiesetrecipients: + koffie, lemburg, loewis, vstinner, serhiy.storchaka, xiang.zhang, John Helour, mdk
2021-06-29 13:12:35koffiesetmessageid: <1624972355.3.0.149581554855.issue24339@roundup.psfhosted.org>
2021-06-29 13:12:35koffielinkissue24339 messages
2021-06-29 13:12:35koffiecreate