Skip to content

[PR] fix(ci): a verified pretest-cache HIT must also touch dist mtimes to now (#4548) - #4549

Closed
ranxianglei wants to merge 1 commit into
masterfrom
2026-10-24_pretest-cache-mtime
Closed

ranxianglei wants to merge 1 commit into
masterfrom
2026-10-24_pretest-cache-mtime

Conversation

@ranxianglei

Copy link
Copy Markdown
Owner

(ai: zai/glm-5.3)

Fixes #4548

这是啥问题?

master 自 10:31Z 起所有测试道红(#3330 的 #3325 mtime 守卫撞上 #4377 的 pretest 缓存):actions/cache 恢复的 kernel/dist 带归档旧时间戳,marker 内容哈希判新鲜跳过重建,守卫按 mtime 判 stale → golden drive 拒跑。全链路见 issue。

修复(2 文件 +63/-2)

  • scripts/ci-pretest-cache.mjs:HIT 分支在 marker 验证通过后递归 utimes 整个 dist 树到当前时间——「被验证新鲜的 dist 也必须是 mtime 新鲜的」,对 test: rebaseline storage-render goldens after remove-absorb (#3309) #3325 守卫/tsup 增量等一切 mtime 消费者成立。守卫本身不动(对本地忘重建的防护仍正确)。
  • tests/ci-pretest-cache.test.ts:新回归测试完整复现事故时序(构建→dist mtime 拨回过去→源文件更新)→ 断言 HIT 不重建 + dist mtime 越过源 mtime;带前置条件断言(恢复后必须先看起来 stale,负向控制)。

验证

能否合并?

纯 fix、单模块(scripts/ci-pretest-cache.mjs + 其测试)、带回归钉、不动配置面/不动 kernel/。按 §7.4 属可自动合并档,但仍等 owner。合并后 master 下一个全量跑即恢复绿(无需清缓存——HIT 路径现在会 touch)。

@ranxianglei ranxianglei changed the title fix(ci): a verified pretest-cache HIT must also touch dist mtimes to now (#4548) [PR] fix(ci): a verified pretest-cache HIT must also touch dist mtimes to now (#4548) Oct 24, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📦 Built Package Artifact

Branch: 2026-10-24_pretest-cache-mtime (2b8d0be)

Latest build — install this exact version

npm install -g billion-context@0.0.5488-pr.4549.501eacf

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
2b8d0be billion-context@0.0.5488-pr.4549.501eacf build

Download artifact

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

Install instructions are refreshed on each push.

@ranxianglei

Copy link
Copy Markdown
Owner Author

(ai: zhipuai-lb/glm-5.3)

陈旧票清理(第三批动作①):目标 issue #4548 已关。为避免重复劳动关闭本 PR;如判断有误请直接 reopen 并留言。

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

Labels

None yet

Projects

None yet

1 participant