ci(spec): retire the generated paths filter — every artifact gate moves to the unfiltered required job - #4292
Merged
Conversation
…oves to the unfiltered required job (#4291) The filter was a hand-maintained duplicate of each gate's input set, and nothing reconciled the two. Its own comment asked for the pair to be kept "in lockstep"; nothing enforced that, and it drifted three times on record — each found by accident and written up in a comment rather than gated: - #2584 moved a generated page and the filter kept watching the old path, so hand-edits to the generated block went unchecked for months. - #3855 listed specific spec paths but no schema dirs, so check:authorable-surface went dormant on exactly the PRs that remove an authorable key. - packages/spec/json-schema.manifest.json was never watched at all. It is the #2978 ratchet and the only durable record of every schema ever emitted, since json-schema/ is gitignored, and build-schemas.ts requires a retirement to delete the key from it — so a manifest-only PR skipped its own verifier. Six of the ten gates had already escaped to lint.yml's typecheck job one at a time, each with a comment explaining that the filter had failed them. This moves the last four — check:skill-docs, check:spec-changes, check:upgrade-guide, check:authorable-surface — and deletes the check-generated job, the `generated` filter, and its output. There is no second ledger left to keep in sync: the failure mode #4255 gated for the check:generated ledger is removed at the source here instead. Affordable because that job was already doing the work: check:docs runs gen:schema — the same scripts/build-schemas.ts that backs check:authorable-surface — and that whole step measures 4s in CI, against a 5-minute job dominated by the workspace build (check:skill-refs 0s, check:react-blocks 1s). All four read source via tsx and need no build, so they run before the workspace build like the gates already there. Safe to delete: needs.filter.outputs.generated had exactly one reader, the job's own `if:`, and lint.yml recorded that the job "is not required, either" — so no branch-protection check disappears. Comments in lint.yml, check-generated.ts and AGENTS.md that described the two-job split are updated to match. Closes #4291 Refs #4255, #2584, #3855, #2978 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QCrKazC5o5a77yXd7ykaZg
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
Contributor
📓 Docs Drift CheckNo hand-written docs reference the 0 changed package(s). ✅ |
os-zhuang
marked this pull request as ready for review
July 31, 2026 03:59
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #4291. Refs #4255, #2584, #3855, #2978.
问题
ci.yml的generatedpaths filter 是每个门输入集合的手工副本,filter 自己的注释要求"keep the two in lockstep",但没有任何东西强制。三次漂移在案,每次都是撞上了才发现、事后补注释而非加门:check:authorable-surface恰好在会删 authorable key 的 PR 上休眠;packages/spec/json-schema.manifest.json从未被覆盖——它是 gen:schema silently drops PageTabsProps since #2967 — references regen would delete real docs #2978 的棘轮台账,且因json-schema/是 gitignore 产物而成为"上次 emit 过哪些 schema"的唯一持久记录;build-schemas.ts要求退役 schema 时从中删 key,但只改 manifest 的 PR 跳过它自己的验证者。10 个门里已有 6 个逐个逃到 lint.yml 的 typecheck job,每次都留注释说明 filter 辜负了它。正确终局不是再加一本账去对第一本账,而是消除重复知识。
修改
check:skill-docs、check:spec-changes、check:upgrade-guide、check:authorable-surface)搬进 lint.yml 的无 filter required job;check-generatedjob、generatedfilter 及其 output(ci.yml −96 行);check-generated.ts头注释与--reconcile-only注释、AGENTS.md 的 spec 产物一节;@objectstack/specpatch。成本实测
check:docs步骤在 CI 里 4 秒,而它 =gen:schema(跑完整build-schemas.ts)+build-docs.ts --check——即那个"可能很贵"的check:authorable-surface跑的是同一个脚本、同一个 job 已在每个 PR 上付过这笔钱。同 job:check:skill-refs0s、check:react-blocks1s、--reconcile-only<1s。整个 typecheck job 5 分 03 秒,其中 3 分 15 秒是 workspace build。4 个门预计加 5–8 秒(约 2%)。四者均经 tsx 读源、无需 build,故置于 workspace build 之前,与已在该 job 的门一致。删除安全性
needs.filter.outputs.generated全仓只有一个读者,即该 job 自己的if:(已随之删除);--reconcile-only回归通过(16 check: + 10 gen: 全部有归属);解析确认 10 个 spec 门现全部集中在唯一的无 filter required job,filter 只剩docs/core。边界
本 PR 不改任何门的判定逻辑,只改它们何时运行。风险面是 CI 编排,不是产物语义。
🤖 Generated with Claude Code
https://claude.ai/code/session_01QCrKazC5o5a77yXd7ykaZg
Generated by Claude Code