◐ Shell
clean mode source ↗

Message 167832 - Python tracker

Note: it is not possible to reencode the buffer of decoded characters to compute the offset in bytes. Some codecs are not bijective.

Examples:

 * b'\x00'.decode('utf7').encode('utf7') == b'+AAA-'
 * b'\xff'.decode('ascii', 'replace').encode('ascii', 'replace') == b'?'
 * b'\xff'.decode('ascii', 'ignore').encode('ascii', 'ignore') == b''