Issue 25287: test_crypt fails on OpenBSD (original) (raw)

Created on 2015-10-01 06:49 by vstinner, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
crypt_openbsd.patch vstinner,2015-10-01 06:49 review
Pull Requests
URL Status Linked Edit
PR 4111 merged serhiy.storchaka,2017-10-24 19:10
PR 4112 merged serhiy.storchaka,2017-10-24 20:20
Messages (8)
msg251998 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2015-10-01 06:49
It looks like crypt.crypt('', crypt.METHOD_CRYPT) returns None. This method must be excluded from crypt.methods. Attached patch should fix the issue, but I didn't try it on OpenBSD. Python 3.4-3.6 is affect, Python 2.7 is not affect (crypt.methods was introduced in Python 3). http://buildbot.python.org/all/builders/x86%20OpenBSD%203.5/builds/186/steps/test/logs/stdio test_saltedcrypt (test.test_crypt.CryptTestCase) ... ERROR ====================================================================== ERROR: test_saltedcrypt (test.test_crypt.CryptTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/python-builds/3.5.borja-openbsd-x86/build/Lib/test/test_crypt.py", line 23, in test_saltedcrypt self.assertEqual(len(pw), method.total_size) TypeError: object of type 'NoneType' has no len() ----------------------------------------------------------------------
msg252158 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2015-10-02 21:02
New changeset 4da7edbf78d4 by Victor Stinner in branch 'default': Issue #25287: Don't add crypt.METHOD_CRYPT to crypt.methods if it's not https://hg.python.org/cpython/rev/4da7edbf78d4
msg252592 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2015-10-09 07:23
Hum, the test now fails differently :-( ====================================================================== FAIL: test_methods (test.test_crypt.CryptTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/python-builds/3.x.borja-openbsd-x86/build/Lib/test/test_crypt.py", line 29, in test_methods self.assertTrue(len(crypt.methods) >= 1) AssertionError: False is not true
msg299193 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2017-07-26 02:59
There is no more OpenBSD buildbot. I have no OpenBSD VM. I just close this old issue.
msg303316 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-09-29 09:10
I have an OpenBSD VM.
msg304929 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-24 16:47
fixes test_crypt in 3.7. In other versions the test should be just skipped on OpenBSD. Blowfish is the only method supported on OpenBSD, but it was not supported by the Python's crypt module.
msg304938 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-24 20:11
New changeset f52dff611cff2fb9e90340b4787eda50ab2d40c6 by Serhiy Storchaka in branch '3.6': bpo-25287: Backport new tests for crypt and skip test_crypt on OpenBSD. (#4111) https://github.com/python/cpython/commit/f52dff611cff2fb9e90340b4787eda50ab2d40c6
msg304940 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-24 20:35
New changeset 04c0a4038e8764f742de8505600b8ee97ee50776 by Serhiy Storchaka in branch '2.7': [2.7] bpo-25287: Backport new tests for crypt and skip test_crypt on OpenBSD. (GH-4111). (#4112) https://github.com/python/cpython/commit/04c0a4038e8764f742de8505600b8ee97ee50776
History
Date User Action Args
2022-04-11 14:58:22 admin set github: 69474
2017-10-24 20:36:06 serhiy.storchaka set status: open -> closedresolution: fixedstage: patch review -> resolved
2017-10-24 20:35:24 serhiy.storchaka set messages: +
2017-10-24 20:20:48 serhiy.storchaka set pull_requests: + <pull%5Frequest4082>
2017-10-24 20:11:48 serhiy.storchaka set messages: +
2017-10-24 19:10:52 serhiy.storchaka set stage: patch reviewpull_requests: + <pull%5Frequest4081>
2017-10-24 16:47:42 serhiy.storchaka set messages: +
2017-09-29 09:44:52 serhiy.storchaka set nosy: + davin
2017-09-29 09:10:11 serhiy.storchaka set status: closed -> opentype: behaviorcomponents: + Library (Lib)versions: + Python 3.7, - Python 3.4, Python 3.5nosy: + serhiy.storchaka, jafomessages: + resolution: out of date -> (no value)stage: resolved -> (no value)
2017-09-29 09:07:11 serhiy.storchaka link issue31633 superseder
2017-07-26 02:59:14 vstinner set status: open -> closedresolution: out of datemessages: + stage: resolved
2016-01-16 20:09:32 ced set nosy: + ced
2015-10-09 07:23:27 vstinner set messages: +
2015-10-02 21:02:42 python-dev set nosy: + python-devmessages: +
2015-10-01 06:50:11 vstinner set nosy: + rpointel
2015-10-01 06:49:50 vstinner create