feat: define contribution and policy-release contracts#17
Conversation
athena-omt
left a comment
There was a problem hiding this comment.
Reviewed as athena-omt. Live state matched head 60a7d4e with CI Gate passing and auto-merge enabled. I checked the contribution lifecycle policy/evaluator, deterministic file-line accounting, DCO/title/independent-review gates, exception and issue-aging behavior, CI wiring, and ran local validation with python3: evaluate_contribution.py plus unittest discovery (30 tests).
athena-omt
left a comment
There was a problem hiding this comment.
Reviewed current head effd930 as athena-omt. Live state was fresh against main, CI Gate was successful, auto-merge was enabled, and there were no active review threads. I checked the policy JSON, evaluator, docs, tests, and CI wiring, and reran the contribution validator plus targeted/full unittest suites locally.
Requesting changes for one current-head issue:
policies/contribution-lifecycle-v1.json:20-23defines the runtime dependency material triggers only for root manifest paths (package.json,pyproject.toml,Cargo.toml,go.mod), andscripts/flow/evaluate_contribution.py:211-217enforces those triggers withfnmatchagainst the full changed path. Nested manifests such aspackages/app/package.json,services/api/pyproject.toml,crates/core/Cargo.toml, orcmd/tool/go.modtherefore do not require theruntime-dependency-additionaction. I verified this against the evaluator: a PR record changingpackages/app/package.jsonwith an emptymaterialClassification.actionslist and an independent approval returns no blocking or warning rule IDs. In a monorepo, that lets runtime dependency additions merge without being classified/notified as material. The smallest good fix is to add nested manifest patterns (for example**/package.json,**/pyproject.toml,**/Cargo.toml,**/go.mod) to the policy andexpected_triggers, then add a regression test showing nested manifests requireruntime-dependency-addition.
|
Addressed the current-head review blocker in
Validation:
CI Gate is queued on the new head. Auto-merge remains enabled. |
2723c29 to
7949e55
Compare
Addressed on current head 7949e55: nested package.json, pyproject.toml, Cargo.toml, and go.mod paths now require runtime-dependency-addition, with regression coverage and green CI.
|
@athena-omt Re-review requested on current head The nested-manifest blocker from the prior review is fixed and covered for |
athena-omt
left a comment
There was a problem hiding this comment.
Reviewed current head 7949e55 on the Athena worker. The branch is fresh against main, CI Gate is successful, and auto-merge is enabled with squash.
Requesting changes for two blockers:
-
policies/contribution-lifecycle-v1.json:10-14/scripts/flow/evaluate_contribution.py:119-123: generateddist/**andbuild/**exclusions only cover root-level output directories. Nested package output such aspackages/app/dist/app.jsorpackages/app/build/app.jsis counted as effective changed lines and can triggerPRS-PR-SIZE-001, even though the docs say generated files are excluded. I reproduced this with the evaluator: rootdist/app.jsandbuild/app.jsare excluded, while nestedpackages/app/dist/app.jsandpackages/app/build/app.jscount as 2000 effective lines and block for size. This is distinct from the already-fixed nested runtime-manifest issue. -
Merge readiness / DCO: commits
ee834eaand60a7d4eare signed off asYour Name <you@example.com>. That placeholder does not provide meaningful DCO contributor identity, while this PR is defining and claiming enforcement of the DCO requirement. Please amend those commit trailers before merge, and ideally harden the evaluator so obvious placeholder sign-offs cannot satisfyPRS-DCO-001.
Checks run locally: python3 scripts/flow/evaluate_contribution.py, python3 scripts/flow/validate_policy_bundle.py, python3 -m unittest discover -s tests -v, JSON parsing, and git diff --check.
Add failing tests for PR size, DCO, conventional titles, independent material review, issue readiness, and 30/90-day aging. Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com>
Add enforceable PR size, DCO, title, independent review, issue readiness, roadmap, aging, and exception contracts with evidence-bound evaluation. Classify nested generated output consistently and reject placeholder DCO identities so policy enforcement matches the contract it defines. Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com>
7949e55 to
c4dc338
Compare
57f7758 to
c4dc338
Compare
|
@athena-omt Re-review requested on repaired current head Both blockers from the prior review are resolved:
Current evidence: CI Gate and all CodeQL checks are green; locally, the full policy suite passed (58 tests), every policy validator passed, and |
* test: define immutable policy release contract Add failing tests for reproducible offline packaging, digest verification, immutable consumer references, and semantic-version upgrade gates. Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com> * feat: package immutable policy releases Add reproducible offline release assets, strict standalone verification, authenticated SemVer upgrade gates, immutable publication, notification, and post-publication evidence. Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com> --------- Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com>
athena-omt
left a comment
There was a problem hiding this comment.
Reviewed current head 0d518f1de38f54f13e34c03233bb6bddeade3077 on the Athena worker. The branch head matches the live PR ref, CI Gate is successful, and squash auto-merge is enabled. I reran the focused validators, full unittest discovery (67 tests), and git diff --check origin/main...HEAD successfully.
Requesting changes for one current-head blocker:
policies/contribution-lifecycle-v1.json:20throughpolicies/contribution-lifecycle-v1.json:23andscripts/flow/evaluate_contribution.py:223throughscripts/flow/evaluate_contribution.py:225still only define/enforce runtime dependency material triggers for root manifest names (package.json,pyproject.toml,Cargo.toml,go.mod). Because enforcement usesfnmatchagainst the full normalized path, nested manifests such aspackages/app/package.json,services/api/pyproject.toml,crates/core/Cargo.toml, andcmd/tool/go.moddo not requireruntime-dependency-addition. I reproduced this on the live head: rootpackage.jsonis rejected withmissing required material actions: runtime-dependency-addition, while those nested manifest paths are accepted with an emptymaterialClassification.actionslist and no blocking or warning rule IDs. This is the previously reviewed runtime-manifest gap still present on the repaired current head; the nested generated-output and placeholder-DCO issues are not being re-raised.
Please add the nested manifest trigger coverage to the policy and validator expectations, plus a regression test alongside test_material_path_trigger_cannot_be_omitted, before merge.
Require material classification for nested package, Python, Rust, and Go dependency manifests, and cover every supported path pattern. Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com>
|
Implemented the requested nested-manifest coverage at commit 157e817.
Validation:
|
athena-omt
left a comment
There was a problem hiding this comment.
Reviewed current head 157e81733a26c02cf1e73d70bc985f4fa3cacb3d on the Athena worker. The branch head matches the live PR ref, CI/CodeQL are successful, and squash auto-merge is enabled. I reran the policy validators, release build/verify, git diff --check, and full unittest discovery (68 tests) successfully. The prior blockers for nested generated-output exclusions, nested runtime manifest triggers, and placeholder DCO trailers appear addressed.
Requesting changes for one current-head blocker:
.github/workflows/policy-release.yml:27through.github/workflows/policy-release.yml:30grants onlycontents: writeandissues: write, but the release evidence gate later callsgh pr view "$REVIEW" --json author,mergeCommit,reviewDecision,stateandgh api "repos/${GITHUB_REPOSITORY}/pulls/${REVIEW}/reviews"at.github/workflows/policy-release.yml:85through.github/workflows/policy-release.yml:89. Because declared workflow permissions leave unspecified scopes unavailable, the GitHub token may not havepull-requests: read, so minor and major policy releases can fail at the exact gate that is supposed to authenticate the merged PR and independent non-author approval. Please addpull-requests: readto the workflow permissions and keep the existing evidence checks.
Allow the release evidence gate to read merged pull request and independent-review metadata while retaining least-privilege permissions. Signed-off-by: John McChesney TenEyck Jr <59268465+jmcte@users.noreply.github.com>
|
Implemented Athena’s workflow-permission request at commit 7d0812b.
Validation:
|
athena-omt
left a comment
There was a problem hiding this comment.
I found no blocking issues on the current head.
Verified the workflow now declares pull-requests: read for the PR/review API calls, and the release evidence gate checks the merged PR state, approved review decision, merge commit matching the tagged commit, and at least one non-author approval. I also reviewed the contribution lifecycle evaluator, deterministic release builder/verifier, policy inventory, and release workflow for auth/provenance regressions.
Validation run:
python3 -m unittest discover -s tests -vpassed, 68 tests.validate_policy_bundle.py,validate_transition.py,evaluate_contribution.py, andvalidate_provenance.pypassed.- Built and verified the policy release offline, then ran the standalone published verifier successfully.
Summary
Governing Issues
Closes #10
Closes #12
Validation
python3 scripts/flow/validate_policy_bundle.py— passedpython3 scripts/flow/validate_transition.py— passedpython3 scripts/flow/evaluate_contribution.py— passedpython3 scripts/flow/validate_provenance.py— passedpython3 -m unittest discover -s tests -v— 68 passedgit diff --check origin/main...HEAD— passedBootstrap Governance
Flow Contract
Flow Merge Readiness
Merge Automation
Auto-merge is enabled with
gh pr merge --auto --squash; CI and non-author approval remain mandatory.Notes
The release changes were added to this existing policy PR before merge, so this description links both governed issues. No production policy reference uses
mainor a floating tag.