Goal
Close gaps where cli/python/base_release/release_bom.py::validate_bom
accepts semantically inconsistent BOM documents.
Background
From the 2026-09-09 deep review of the release-BOM feature (Base 1.9.0). None
of these is exploited by the current Ecosystem Release BOM workflow (which
builds rows consistently via jq and bin/base-release-bom-row), but
validate_bom is the contract of record and is invoked directly by
bin/base-release-bom validate and by basectl release check/publish --bom.
- Component
tag is checked against TAG_RE but never against
v{component.version}. release.tag is cross-checked
(release_bom.py ~line 49); component rows are not.
- The release repository's own component row
commit is not checked against
release.commit; they may diverge.
combinations[].platform is a free string and is not required to appear in
any participant's platforms array.
release.version (and component version) are validated only as
non-empty strings, while release.tag must match ^v[0-9]+\.[0-9]+\.[0-9]+$
and equal v<version> -- so release.version = "01.9.0" slips through.
REPOSITORY_RE = ^[^/\s]+/[^/\s]+$ accepts values such as ../foo.
Scope
cli/python/base_release/release_bom.py::validate_bom:
- non-moving component rows: require
tag == f"v{version}".
- the component row whose
repository equals release.repository: require
commit == release.commit.
- each
combinations[].platform: require it to be listed by every
participant's component platforms (or by at least one -- decide and
document the rule).
- apply strict SemVer to
release.version and component version.
- tighten
REPOSITORY_RE to reject . / .. path segments.
docs/schemas/release-bom.schema.json and docs/release-bom.md: reflect
the tightened rules (coordinate with the schema-reconciliation issue).
cli/python/base_release/tests/test_release_bom.py: a dedicated failing
test for each of the five items.
Acceptance Criteria
Validation
python -m pytest cli/python/base_release/tests/test_release_bom.py -q
bin/base-release-bom validate tests/fixtures/release-bom-valid.json \
--repository basefoundry/base-bash-libs --version 2.1.0
bin/base-test
Non-Goals
- No new required or optional BOM fields.
- No
schema_version bump unless the schema-reconciliation issue concludes
one is required.
- Not changing how the workflow assembles rows (covered by the workflow
hardening issue).
Project Fields
- Status: Backlog
- Priority: P3
- Size: S
- Area: Packaging
- Initiative: Contract Hardening
- Milestone: v1.10.0
Agent Assignment
Human first; Copilot candidate after triage once the combinations[].platform
rule (all vs any participant) is decided.
Goal
Close gaps where
cli/python/base_release/release_bom.py::validate_bomaccepts semantically inconsistent BOM documents.
Background
From the 2026-09-09 deep review of the release-BOM feature (Base 1.9.0). None
of these is exploited by the current
Ecosystem Release BOMworkflow (whichbuilds rows consistently via
jqandbin/base-release-bom-row), butvalidate_bomis the contract of record and is invoked directly bybin/base-release-bom validateand bybasectl release check/publish --bom.tagis checked againstTAG_REbut never againstv{component.version}.release.tagis cross-checked(
release_bom.py~line 49); component rows are not.commitis not checked againstrelease.commit; they may diverge.combinations[].platformis a free string and is not required to appear inany participant's
platformsarray.release.version(and componentversion) are validated only asnon-empty strings, while
release.tagmust match^v[0-9]+\.[0-9]+\.[0-9]+$and equal
v<version>-- sorelease.version = "01.9.0"slips through.REPOSITORY_RE = ^[^/\s]+/[^/\s]+$accepts values such as../foo.Scope
cli/python/base_release/release_bom.py::validate_bom:tag == f"v{version}".repositoryequalsrelease.repository: requirecommit == release.commit.combinations[].platform: require it to be listed by everyparticipant's component
platforms(or by at least one -- decide anddocument the rule).
release.versionand componentversion.REPOSITORY_REto reject./..path segments.docs/schemas/release-bom.schema.jsonanddocs/release-bom.md: reflectthe tightened rules (coordinate with the schema-reconciliation issue).
cli/python/base_release/tests/test_release_bom.py: a dedicated failingtest for each of the five items.
Acceptance Criteria
by
validate_bomwith a clear message.tests/fixtures/release-bom-valid.jsonand a CI-assembled BOM stillvalidate.
docs/release-bom.mdupdated to match, or theschema-reconciliation harness enforces the agreement.
Validation
Non-Goals
schema_versionbump unless the schema-reconciliation issue concludesone is required.
hardening issue).
Project Fields
Agent Assignment
Human first; Copilot candidate after triage once the
combinations[].platformrule (all vs any participant) is decided.