Repository navigation
fix(ci): stop tier-1 guards from skipping test/static-gates on non-PR events (#2901) - #2907
ranxianglei wants to merge 1 commit into
Conversation
📦 Built Package ArtifactBranch: Option A — Install this exact build (recommended)npm install -g billion-context@0.0.3238-pr.2907.262e320This exact version is immutable and reproducible. The rolling Option B — Download artifact
tar xzf billion-context-pr2907.tgz
npm install -g packageInstall instructions are refreshed on each push. |
c4fdfa5 to
b03db93
Compare
… events (#2901) #2637's fail-fast tiering gated version/kernel/pi-subagents/lane-guard with 'if: pull_request' on the assumption that skipped needs count as satisfied. That is not what GitHub Actions does: a needed job skipped via if blocks its dependents, so since bc6e327 every master push, release-branch push and workflow_dispatch showed test+static-gates = skipped — master's own CI never ran the suite (the blind spot through which #2782's unregistered spawner shipped undetected; #2896/#2901). Remove the four event gates so all eight needs run on every event. The guards are inert by construction on non-PR events: their checks are three-dot diffs against origin/master (empty on a push to master), and version-guard/kernel-guard fall back from GITHUB_HEAD_REF to GITHUB_REF so *_release-v*, bugfix-release/* and *_release-kernel-v* branches keep their exemptions. PR flow is unchanged (GITHUB_HEAD_REF takes precedence). Behavior change: non-PR runs execute the full test + static-gates matrix again (pre-#2637 behavior restored) plus four ~10s zero-dep guard jobs.
b03db93 to
ecdeced
Compare
[bot] 🏷 PR #2907 review 结论(核对代码 + 确认 CI;未重做,仅按「CI 失败→修正」补了一次 rebase) 先说做了什么:这是 按结构化八问:
诚实标注无法本地证明的一点:needs 级联真正修复的最终证明需合并后的一次 master push 显示腿真实执行——本地无法模拟 GH Actions 的 push 事件,PR 本身也注明了这点。当前证据链:代码逐行核对正确 + 8 个 job 按各事件类型逐一推演通过 + rebase 后 CI 实跑中 guard/static-gates 全绿、test 腿真实运行(tripwire 已解除)。 判定:diff 干净(单文件 ci.yml)、方向正确、stale-base 已修、tripwire 已由 #2898 落地。待本次 CI(ecdeced72)全绿即可合并——目前 13 腿已绿、test/static-gates 矩阵运行中,预期转绿。合并请人工操作(按规约我不 merge)。 |
[bot] 🏷 CI 更新(rebase 后 head ecdeced):18 腿中已 17 绿 —— 8 guard + build-artifact + docs-sync/docs-coverage + config-surface-guard + 全部 这直接证实了 stale-base 修复有效:rebase 到当前 master(含 #2898 的 判定不变:diff 干净(单文件 ci.yml)、方向正确、CI 实质全绿。可合并 —— 合并请人工操作(按规约我不 merge)。 |
#2901 建议修法第 3 条:恢复非 PR 事件(master push / release push / dispatch)上的真实测试运行。第 ①② 条(LIVE_FILES 登记)已由 #2898 在重复报告 issue #2896 下处理,本 PR 刻意不含该 diff。
Root cause
#2637(commit 6b0c7b4,fail-fast tiering)给
test/static-gates加了含四个if: github.event_name == 'pull_request'守卫的needs:。提交注释假设 "skipped needs count as satisfied" —— GitHub Actions 的实际行为相反:被if跳过的 needed job 会连带跳过其依赖者。本仓实证:test (ubuntu-latest, 22/24)+ windows 全 success);test=skipped、static-gates=skipped(核查了 bc6e327 / 60c47ba / f5631ed / e343744 / 467b0f6 / c60c2d1)。issue 里「merge commit 才 skip」的表述实际是按事件类型:所有 push 都 skip;Fix
移除四个守卫的
if: pull_request门,让全部 8 个 needs 在每个事件上都执行。非 PR 事件下守卫按构造即 inert:origin/master的三点 diff(master push 上为空 → 通过);BRANCH="${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}"—— push/dispatch 下 GITHUB_HEAD_REF 为空,回退到被推分支名,保住*_release-v*/bugfix-release/*/*_release-kernel-v*豁免(one-click fallback 分支命名YYYY-MM-DD_release-v{VER}[-HHMMSS],匹配该模式);Behavior change(old → new)
代价:每次非 PR 运行多 4 个 ~10s 零依赖守卫 job。附带效果:
scripts/release-ci-gate.mjs --wait(严格:只看 run 级 success)过去在 one-click publish sha 上是零测试覆盖就放行(腿被 skip);此后要求 publish sha 有真实绿套件——这是第 ③ 条意图内的收紧。Verification
test腿会在已知的 master 侧 tripwire(issue2752 未登记 LIVE_FILES)处红——与本 diff 无关;fix: register issue2752 forward-partial-outcome suite in LIVE_FILES (#2896) #2898 落地后重跑即可转绿。static-gates腿独立验证本树。Config surface: none(CI workflow only).