ci: bind TKE merge runs to the exact merged subject - #441
Conversation
|
Reviewed exact head I traced the complete subject-identity chain:
The concrete failing case also lines up: run 33447333340 carried default-branch Validation at this head:
I also checked merge-method semantics: after a PR is merged, GitHub defines |
Ariznawlll
left a comment
There was a problem hiding this comment.
复核 exact head cd6eb59aa44b1f3489f39170d935f0730beef7b2,未发现 blocking 问题。
已核对完整 subject identity 链路:镜像构建 checkout pull_request.merge_commit_sha 并校验实际完整 SHA;Setup、两个 CN 内资源 checkout 和 BVT 全部消费同一个已验证的 full_commit_id;workflow 不再使用 github.sha 或 github.ref_name 作为 MatrixOne subject。该字段在 PR 合并后也能正确覆盖 merge、squash 和 rebase 三种正常合并方式。
验证结果:新增 subject contract 3/3 PASS,原有 coverage-selection contract 9/9 PASS,YAML parse PASS,git diff --check PASS,exact-head workflow check PASS。未触发或重跑任何 TKE/CI 测试环境。
Problem
TKE checkin runs are triggered by pull_request_target. actions/checkout without an explicit ref resolves the repository default branch, so a PR merged into 4.2-dev built and tested an unrelated main commit. Run 33447333340 requested merge commit 60fb48f but built commit-b23beee.
Fix
The merged commit is already part of the trusted base repository; no unmerged PR head is executed.
Validation