Repository navigation
chore: pin warm-image snapshot compatibility keys - #171880
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 19a12565ff
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| expect(resolveCrabboxWarmImageProfileKey(profile)).toBe( | ||
| "6b01b9af04cfd3441ea20fde45d9951b39cf4c2da9a5df3c62dd8a1929725254", | ||
| ); |
There was a problem hiding this comment.
Pin the project-scoped snapshot key
For project-backed Crabbox allocations, selectAllocation passes context.projectKey into this resolver (crabbox-worker-warm-image.ts:340), but this golden omits that argument. A change confined to the projectKey field name, placement, or encoding would therefore leave the new golden tests green while changing the actual snapshot-store key and sending project sessions through cold setup. Add an exact golden using a representative project key as well.
AGENTS.md reference: AGENTS.md:L50-L53
Useful? React with 👍 / 👎.
A live Gateway update on 2026-10-14 silently sent the next cloud session cold: openclaw#171073 had (deliberately) changed the warm-image profile fingerprint for every profile, and the only test touching the key asserted that it differed from an old value, never what it is. Golden tests now pin the exact Crabbox warm-image profile key and the preparation and cache keys for one canonical Linux profile without setup secrets, each with a note that changing the value invalidates every user's warm images on update and must be deliberate and explained. Test-only; no production change and no key change. Refs: openclaw#171880
What Problem This Solves
Warm-image key changes can silently send every user's next cloud session through cold setup after a Gateway update.
User Impact
No user-visible behavior changes: the current snapshot key bytes remain unchanged. Release-note context: test coverage now requires deliberate, explained changes to warm-image compatibility keys.
Why This Change Was Made
Pin the exact SHA-256 key for the canonical AWS/Linux
tinyprofile with warm images enabled, no desktop, no setup command, and no setup secrets. Pin the existing repository recipe fixture's preparation readiness key (key) and reusable diskcacheKeyat their owner, reusing its provider-fingerprint test setup. Each golden warns that changes invalidate warm images and must be deliberate and explained in the PR.Keep the existing negative assertion for protected-egress keys: it independently prevents adopting retired plaintext setup images. No production changes, removals, migration, or changelog edits.
Evidence
pnpm test extensions/crabbox/src/crabbox-worker-profile.test.ts src/gateway/worker-environments/preparation-identity.test.ts --maxWorkers=1— 38 tests; 13.68 s wall total. Gateway file: 21 tests, 3.09 s runner duration; Crabbox file: 17 tests, 3.15 s runner duration.pnpm format:check --no-error-on-unmatched-pattern -- extensions/crabbox/src/crabbox-worker-profile.test.ts src/gateway/worker-environments/preparation-identity.test.ts— 0.60 s.node scripts/run-oxlint.mjs --tsconfig config/tsconfig/oxlint.core.json src/gateway/worker-environments/preparation-identity.test.ts— 191.27 s, including waiting for declaration preparation.node scripts/run-oxlint.mjs --tsconfig extensions/tsconfig.json extensions/crabbox/src/crabbox-worker-profile.test.ts— 174.64 s, including plugin SDK declaration preparation.node scripts/run-tsgo.mjs -p .artifacts/tsconfig.golden-snapshot-keys.json --noEmit— 38.80 s. Local ignored config extends the repository test config and includes the two touched tests plus existing declarations.git diff --check— 0.30 s.Tooling attempts: the first autoreview preflight rejected the shared temporary directory (22.78 s); the completed review used the macOS private temporary directory. The changed-path typecheck planner expanded to unrelated test graphs and was stopped before running them (99.82 s, exit 143); the two-file config above replaced it. No test failures, skipped tests, timeout increases, or baseline changes. CI runtime remains pending.