Skip to content

[PR] fix(ci): intermediate pushes marked [ework:ci-held] no longer trigger PR CI (only the final push triggers a full run) | fix(ci): [ework:ci-held] 标记的中间 push 不再触发 PR CI(最终 push 唯一全量) - #6784

Merged
ranxianglei merged 1 commit into
masterfrom
2026-11-15_ci-held-push-suppression
Nov 15, 2026

Conversation

@ranxianglei

Copy link
Copy Markdown
Owner

(ai: anthropic/claude-sonnet-4-5)

Fixes #6783

改了什么

全部 20 个 pull_request 触发的 workflow、42 个 job 统一加:

if: ${{ !contains(github.event.head_commit.message, '[ework:ci-held]') }}

已有 if: 的 job 用 && 合并进原条件(42/42 校验过)。ci.yml 头部加了 #CI-hold 契约注释(单一文档源)。

语义

  • commit message(subject 或 body)含 [ework:ci-held] 的 push → 该 run 全部 job skipped,秒完,不烧 runner;
  • 不带标记的最终 head push = 该分支唯一一次全量 CI(=「推一堆后确定没问题再触发」,owner 2026-11-15 定案);
  • schedule / workflow_dispatch / master push 的 run 不受影响(head_commit 空或非 PR 事件 → guard 恒真);
  • 带标记期间必过 checks 为 skipped → PR 不可合并,这是「CI 还没正式触发」的正确信号;
  • 边界:分支若停在带标记的 head(会话中断),下一次唤醒收尾并推无标记最终 commit 即恢复。

为什么不用别的方案

配套

e-work 侧 ci-engineer 提示词(push 纪律:中间 commit 带标记、最终 head 不带 + 唤醒时检查 head 是否停在标记态)是 ranxianglei/ework 的另一个 PR,单独走。

预检

  • 20 个 yml 全部 yaml.safe_load 通过;
  • 脚本校验:每个 PR 触发 workflow 的每个 job 的 if 均含 guard(42/42);
  • 本 PR 自己的 push 不带标记,全量 CI 会正常跑 = 同时是对该 PR 自身的验证。

Every pull_request-triggered job in all 20 PR workflows now carries
`if: !contains(github.event.head_commit.message, '[ework:ci-held]')`,
merged with pre-existing job conditions where present.

Why: the ci-engineer lane rebase/fix sessions push incrementally, and
each push spawned ~13 full workflow runs. Queued runs on the same ref
are NOT cancelled by the per-ref concurrency groups (cancel-in-progress
only covers in_progress), so a 20-push session queued ~260 runs that
starved real work (release CI waited behind 73 queued, #5795 incident
lineage). Owner policy 2026-11-15: intermediate pushes must not trigger
CI; the verified final head push (marker-free) is the single CI pass.

Semantics: marker in the commit MESSAGE (subject or body) — GitHub only
exposes head_commit.message at trigger time. Non-PR events are
unaffected (schedule/workflow_dispatch/empty head_commit => guard true).
A held run completes with all jobs skipped; branch-protection required
checks stay unsatisfied until the final unmarked run goes green, which
is the intended signal that "CI has not been asked yet".

No config surface added (owner policy: marker convention, not a knob).

(ework-agent, policy: 推一堆后确定没问题再触发 — m17242)
@github-actions

Copy link
Copy Markdown
Contributor

📦 Built Package Artifact

Branch: 2026-11-15_ci-held-push-suppression (656400d)

Latest build — install this exact version

npm install -g billion-context@0.0.10048-pr.6784.2259660

This exact version is immutable and reproducible. The rolling pr tag tracks the newest test build across all PRs.

Recent builds (commit → version)

commit version build
656400d billion-context@0.0.10048-pr.6784.2259660 build

Download artifact

  1. Download the artifact from the Actions run
  2. Extract the tarball and install:
tar xzf billion-context-pr6784.tgz
npm install -g package

Install instructions are refreshed on each push.

@ranxianglei ranxianglei changed the title fix(ci): [ework:ci-held] 标记的中间 push 不再触发 PR CI(最终 push 唯一全量) [PR] fix(ci): intermediate pushes marked [ework:ci-held] no longer trigger PR CI (only the final push triggers a full run) | fix(ci): [ework:ci-held] 标记的中间 push 不再触发 PR CI(最终 push 唯一全量) Nov 15, 2026
@ranxianglei
ranxianglei merged commit faf0af6 into master Nov 15, 2026
104 of 150 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

📦 Merged Build Published

This merge to master was published as 0.0.1200-master.faf0af6 (rolling master tag).

npm install -g billion-context@0.0.1200-master.faf0af6  # this exact build
npm install -g billion-context@master  # always the newest merged build

npm view billion-context@master prints the current version at any time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

1 participant