New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
uuid - exception on uuid3/uuid5 #47802
Comments
The test suite breaks on the Lib/test/test_uuid.py, as of r65661. This TypeError: new() argument 1 must be bytes or read-only buffer, not bytearray The problem is due to the changes in the way "s#" now expects a A rundown of the problem: Lib/uuid.py:553 (in uuid.uuid3): namespace.bytes is a bytearray, so the argument to md5 is a bytearray. Modules/md5module.c:517 (in _md5.md5.new): Using s# now requires a read-only buffer, so this raises a TypeError. The same goes for uuid5 (which calls _sha1.sha1, and has exactly the The commit log for r65561 suggests changing some s# into s* (which In the meantime, I propose this simple patch to fix uuid: I think Related issue: Patch for r65675. Fixed TypeError raised by uuid.uuid3 and uuid.uuid5, by passing a |
I couldn't reproduce the problem (and apparently, many of the buildbots |
So are you saying that if I had libopenssl (or whatever the name is) That would indicate that the bots _aren't_ testing the code in _md5 and |
Correct. Those modules aren't even built then. See openssl_ver in setup.py.
Most of them, yes, to be able to test openssl. You would have to check
Perhaps. However, the buildbots can't test all combinations, anyway. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: