Repository navigation
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
|
Validated with the following test data: All scenarios use this sbom:
supplier: "Organization: ExampleCo"
namespace: "https://sbom.example"
One small nit: the |
|
Can you also please squash both of the commits since the second one just fixes the indentation of the header? |
Derive the default source purl from the resolved package, while preserving explicit upstream purls. Document the configuration migration and cover name, type, namespace, and global type overrides. Co-Authored-By: Hermes Agent <[email protected]> Closes: python-wheel-build#1383 Signed-off-by: Emre K <[email protected]>
3522bfb to
dba98b3
Compare
|
Thanks for checking the scenarios. I changed |
Pull Request Description
What
purl.upstreamstill takes precedence.SbomSettings.purl_typeapplies to wheel package entries.Why
Closes #1383. Previously the
GENERATED_FROMentry could identify a downstream-renamed wheel rather than the resolved PyPI source. This changes existing SBOM output for users overriding purl type/name/namespace withoutpurl.upstream; set that field explicitly for a different source.Verification
uvx --from hatch hatch run test:test tests/test_sbom.py::test_generate_sbom_upstream_ignores_wheel_purl_overrides -q --no-cov --tb=short→ 4 expected upstream identity assertion failures (original test-first cycle).SbomSettings.purl_typesaid “all packages”; GREEN: same check passed after making it wheel-only.uvx --from hatch hatch run test:test tests/test_sbom.py tests/test_packagesettings.py -q --no-cov --tb=short→ 112 passed.uvx --from hatch hatch run lint:check→ passed;uvx --from hatch hatch run mypy:check src/fromager/sbom.py src/fromager/packagesettings/_models.py tests/test_sbom.py→ 77 source, 51 test, 7 e2e files checked, no issues.uvx --from hatch hatch run docs:build→ build succeeded;git diff --check HEAD~1..HEAD→ passed. Full suite/e2e not run locally (repo guidance favors file-scoped tests for small changes). The original two signed-off commits, including the Sphinx heading correction, were squashed into one signed-off commit at maintainer request; CI is rerunning for the new head.Significant AI assistance: Hermes Agent co-authored the patch; test failures and passing checks were run locally.