ci: require t4-conformance success except on fork PRs (mc#21) #142
Reference in New Issue
Block a user
Delete Branch "fix/t4-validate-fork-only-skip"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes molecule-ci#21.
The validate aggregator previously accepted a skipped T4 result for any event, letting internal PRs/main pushes go green without a live gate run. T4 is a hard gate; only fork PRs legitimately skip it.
is_fork_prfromgithub.event_name+head.repo.fork.skippedt4 only on fork PRs.pushand internalpull_request.Test plan
validatejob should still pass because the T4 job runs and succeeds on internal PRs.APPROVED. 5-axis review passed for current head
9fd3a164.Correctness: the validate aggregate now treats T4 conformance as a hard gate for internal PRs and main pushes, while preserving the legitimate fork-PR skip path. This fixes the prior fail-open behavior where any skipped T4 could let the aggregate pass.
Robustness: unexpected T4 states still fail closed; fork detection is limited to pull_request events. Documentation updates are consistent with the local-build fallback note.
Security: no token or permission expansion; the gate strengthens live-conformance enforcement for trusted branches/PRs.
Performance/ops: no runtime path changes; CI behavior becomes stricter only where the live gate should run.
Readability/tests: workflow comments explain the policy clearly, and latest required CI/template/T4/adapter/secret-scan/provider-projection contexts are green. Note: #145 contains this same gate fix plus an additional push-trigger narrowing, so it may supersede this PR operationally, but this PR is sound on its own.
5-axis review: APPROVED at head
9fd3a164.The CI aggregate change strengthens the T4 conformance requirement: non-fork PRs/main pushes now require
success, whileskippedis only accepted for fork PRs where the live gate cannot run. This does not drop required-context coverage. The accompanying runbook/known-issues additions accurately document the local-build fallback whenMOLECULE_IMAGE_REGISTRYis unset. No security/performance regression; CI reported green and PR is mergeable.