Message402726
I am working on it, since it is more complex issue, and PR 13134 does not solve it.
1. This bug affects also other codecs implemented in C: ASCII, Latin1, UTF-8, etc.
2. It still crashes in UTF-16/32 encoders if the error handler returns a position less than the current position.
3. Incorrect exception can be raised if the error handler returns invalid string/bytes: a non-ASCII string or a bytes object consisting of not a whole number of units.
4. The code for standard error handlers and for decoders needs a revision too. I have some suspects.
We could just forbid error handlers returning position not in the range (start , end], but it can break some code, so it is better to do this only in a new release. |
|
Date |
User |
Action |
Args |
2021-09-27 15:02:52 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, vstinner, anthonypjshaw, atalaba, iritkatriel |
2021-09-27 15:02:52 | serhiy.storchaka | set | messageid: <1632754972.66.0.0623653314448.issue36819@roundup.psfhosted.org> |
2021-09-27 15:02:52 | serhiy.storchaka | link | issue36819 messages |
2021-09-27 15:02:52 | serhiy.storchaka | create | |
|