You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
FEATURE: Support for requirements.txt files with hashes #8
PEP-440 has references to hashes for local and remote package definitions
Support for parsing a requirement with hashes using pkg_resources.parse_requirements() appears to be limited particularly when the requirement spans more than 2 lines (i.e. more than one continuation \).
Additional tests added ti demonstrate the current limitations with requirements.txt parsing.
Further investigation required as it's not clear that --hashes is officially part of the Python standard at this time.
Activity
test: additional tests around issue #8 which confirm level of support…
madpah commentedon Sep 17, 2021
References:
Support for parsing a requirement with hashes using
pkg_resources.parse_requirements()appears to be limited particularly when the requirement spans more than 2 lines (i.e. more than one continuation\).Additional tests added ti demonstrate the current limitations with
requirements.txtparsing.Further investigation required as it's not clear that
--hashesis officially part of the Python standard at this time.sbs2001 commentedon Nov 16, 2021
@madpah looks like
--hashis supported but it seems to be only a pip feature pypa/packaging#488 . See https://github.com/pypa/pip/blob/main/docs/html/reference/requirements-file-format.md#per-requirement-options and there's multiple references to it in pip to handle it https://github.com/pypa/pip/search?q=%22--hash%22 .So I can think of two ways to handle this:
Or
jkowalleck commentedon Jan 8, 2022
yet another point of view: CycloneDX/cyclonedx-python#194 (comment)
jkowalleck commentedon Feb 27, 2022
see CycloneDX/cyclonedx-python#319
for discussion.
mostafa commentedon Mar 17, 2022
@madpah @jkowalleck I think this can be closed because of CycloneDX/cyclonedx-python#327.
madpah commentedon Apr 20, 2022
Agree @mostafa - thanks!