Tests fail when OpenSSL FIPS is enabled
- Dominant language
- Python
- Stars
- 1.1k
- Forks
- 155
- PR merge metrics
- No merged PRs in 30d
Description
```
path/__init__.py .....F................ [ 15%]
path/masks.py ..... [ 19%]
tests/test_path.py ...................................................s. [ 56%]
..............................................sssssss......... [100%]
=================================== FAILURES ===================================
__________________________ [doctest] path.Path.chunks __________________________
802 Returns a generator yielding chunks of the file, so it can
803 be read piece by piece with a simple for loop.
804
805 Any argument you pass after `size` will be passed to :meth:`open`.
806
807 :example:
808
809 >>> hash = hashlib.md5()
UNEXPECTED EXCEPTION: UnsupportedDigestmodError('[digital envelope routines] unsupported')
Traceback (most recent call last):
File "/nix/store/rk8pycgcvbid0asn2zdb4jl8ri92nz0d-python3-3.13.6/lib/python3.13/doctest.py", line 1395, in __run
exec(compile(example.source, filename, "single",
~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
compileflags, True), test.globs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1, in
_hashlib.UnsupportedDigestmodError: [digital envelope routines] unsupported
/build/path-17.1.1/path/__init__.py:809: UnexpectedException
=========================== short test summary info ============================
FAILED path/__init__.py::path.Path.chunks
============ 1 failed, 133 passed, 8 skipped, 1 deselected in 5.78s ============
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the Path.chunks doctest in path/__init__.py around line 809 and reproduce the failure with OpenSSL FIPS enabled. Determine the expected behavior for the hashlib.md5 example under that configuration; done means the relevant test suite passes without the FIPS-related exception.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- security, testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 45/100