Tests fail when OpenSSL FIPS is enabled
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- python
- Domain
- security, testing-qa
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.
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 "<doctest path.Path.chunks[0]>", line 1, in <module>
_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 ============
- Dominant language
- Python
- Stars
- 1.1k
- Forks
- 172
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from jaraco/path
-
merge_tree(symlinks=True) cannot overwrite an existing destination symlinkMay be free again A pull request for this issue was closed without being merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
`Path.cwd()` is missing a return type annotationPossibly taken @purplezimmermann claimed this 296 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 55/100
-
`pygments` and `types-pywin32` should be moved to extrasPossibly taken @agammann claimed this 52 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 48/100
-
help wanted
Difficulty 5/5 Over a week Newbie friendliness 35/100
Similar issues
-
area:cli area:security bug priority:medium
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
docs pydanty:is-working
Difficulty 1/5 Under an hour Newbie friendliness 88/100
pydantic/pydantic-ai#13563 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
NCATSTranslator/Babel#1204 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
alltheplaces/alltheplaces#20570 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
sio2project/oioioi#981 · 1 reaction ·
Maintainers usually reply within 1 day