GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — `euc_jp` and `gb18030` incremental decoders drop input after an incomplete trailing sequence under `surrogateescape` · Issue #160307 · python/cpython Open Labels extension-modulesC modules in the Modules dirC modules in the Modules dirtype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error DescriptionBug descriptionWith >>> import codecs >>> b'\x8f\x00'.decode('euc_jp', 'surrogateescape') '\udc8f\x00' >>> codecs.getincrementaldecoder('euc_jp')('surrogateescape').decode(b'\x8f\x00', final=True) '\udc8f' >>> b'\x806'.decode('gb18030', 'surrogateescape') '\udc806' >>> codecs.getincrementaldecoder('gb18030')('surrogateescape').decode(b'\x806', final=True) '\udc80' The >>> import io >>> io.TextIOWrapper(io.BytesIO(b'\xa8\x8fl'), encoding='euc_jp', errors='surrogateescape').read() '\udca8\udc8f' The other handlers do not lose anything because they consume the whole trailing range in one go ( Found by the Hypothesis tests in #160155, where it is pinned as CPython versions tested onCPython main (6e1bd24) Operating systems tested onLinux Linked PRsActivity
MetadataMetadataAssigneesLabelsextension-modulesC modules in the Modules dirC modules in the Modules dirtype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error ProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |