| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| raise ValueError(f"Couldn't fetch metadata for project '{project}' from PyPI: {e}") | ||
|
|
||
|
|
||
| def remove_pip_from_sbom(sbom_data: dict[str, typing.Any]) -> None: |
There was a problem hiding this comment.
I'll be able to remove this function once I remove pip from the SBOM in the CPython source code.
Sorry, something went wrong.
| "Tarball doesn't contain an SBOM at 'Misc/sbom.spdx.json'" | ||
| ) from None | ||
| sbom_bytes = tarball.extractfile(sbom_tarball_member).read() | ||
| sbom_data = json.loads(sbom_bytes) |
There was a problem hiding this comment.
Changed this variable name to match everywhere in this script.
Sorry, something went wrong.
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
There was a problem hiding this comment.
There will be a follow-up PR to the CPython repository removing the machinery there once this PR lands.
And after that update https://devguide.python.org/developer-workflow/sbom/.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Closes #91 This moves the pip SBOM discovery machinery from the CPython repository to this repository to not require pip maintainers to update the SBOM every time, saving difficulties with backporting and a bunch of manual effort.
There will be a follow-up PR to the CPython repository removing the machinery there once this PR lands.
The SBOM diff between running this script on Python-3.12.2.tgz:
Notice this removes all the direct relationships between CPython and pip's subpackages, this is a good thing IMO since CPython doesn't directly depend on these packages. This still lets tools like scanners discover vulnerabilities because CPython still has a dependency relationship with pip.