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 serhiy.storchaka
Recipients serhiy.storchaka, vstinner
Date 2017-09-29.06:29:09
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I tried to build CPython on 64-bit OpenBSD. It was built successfully, but tests crash. They crash on importing hashlib. Actually on compiling hashlib docstring. Minimal reproducer is:

$ ./python -c 'import codecs; codecs.decode(r"\\"*15 + "x"*1906, "unicode-escape")'                  
assertion "maxchar < 128" failed: file "Objects/unicodeobject.c", line 474, function "_PyUnicode_CheckConsistency"
Abort trap (core dumped) 

_PyUnicodeWriter_Finish() calls resize_compact() for truncating the result, but the latter fills the last 15 bytes with \xdb. Since the string is tagged as ASCII, thus crashing in _PyUnicode_CheckConsistency.
Date User Action Args
2017-09-29 06:29:10serhiy.storchakasetrecipients: + serhiy.storchaka, vstinner
2017-09-29 06:29:10serhiy.storchakasetmessageid: <>
2017-09-29 06:29:10serhiy.storchakalinkissue31626 messages
2017-09-29 06:29:09serhiy.storchakacreate