mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-08-25 08:22:42 +00:00
test(cache): make the round-2 review findings fail when broken
Round 2 of the independent review proved five things by mutation: it broke the behavior and the tests stayed green. Every one is now pinned. The most important invariant in this change was the least guarded. Copilot must have NO entry in PROVIDER_ENV_VARS - declaring any of its nine reads moves its fingerprint and re-opens the durable history-loss path - but only one of the nine was covered, so declaring any of the other eight passed the whole suite. Now the absence of the entry is asserted directly, and all nine vars are table-tested for fingerprint stability. Doctor stops blaming parse-only overrides for a failed discovery. CODEBURN_CURSOR_MAX_BUBBLES caps how many bubbles Cursor parses and KIMI_MODEL_NAME renames an attributed model; neither relocates anything, so "NOTHING FOUND (override CODEBURN_CURSOR_MAX_BUBBLES set...)" pointed the user at the wrong thing. Both join NON_DISCOVERY_ENV_VARS, which exists for exactly this, and both still appear in Details - only the verdict's blame line changes. The secret-redaction and ambient-suppression tests are table-driven over both names each covers, since removing either second name (VERCEL_OIDC_TOKEN, LOCALAPPDATA) previously leaked or surfaced it with every test still passing. The changelog no longer claims a one-time re-parse for the Vercel gateway: it is a network provider re-fetched on every writable run, so its declaration is a read-only-path correction, not a migration. Fourteen file-backed providers migrate once.
This commit is contained in:
parent
9c9a37d4bf
commit
a67bd279a6
4 changed files with 136 additions and 54 deletions
|
|
@ -99,10 +99,18 @@ const PARSE_CALL_CAP = 500
|
|||
// (readdir/stat only) still runs, so session counts stay meaningful.
|
||||
const PARSE_SPAWNS = new Set(['antigravity'])
|
||||
|
||||
// CodeBurn's own cache location: listed in PROVIDER_ENV_VARS for cache
|
||||
// fingerprinting, but it is not a discovery path, so it must never be blamed
|
||||
// in a NOTHING FOUND hint.
|
||||
const NON_DISCOVERY_ENV_VARS = new Set(['CODEBURN_CACHE_DIR'])
|
||||
// Vars listed in PROVIDER_ENV_VARS for cache fingerprinting that are NOT
|
||||
// discovery paths: a change to them can never explain "nothing was
|
||||
// discovered", so they must never be blamed in a NOTHING FOUND hint.
|
||||
// - CODEBURN_CACHE_DIR: CodeBurn's own cache location — where the cache
|
||||
// file lives, not where sessions are discovered.
|
||||
// - CODEBURN_CURSOR_MAX_BUBBLES: caps how many bubbles Cursor parses
|
||||
// (src/providers/cursor.ts:692) — a parse budget, not a discovery root.
|
||||
// - KIMI_MODEL_NAME: renames the model attributed to Kimi sessions
|
||||
// (src/providers/kimi.ts:155) — attribution, not discovery.
|
||||
// All three still appear in the Details block; only the verdict's blame line
|
||||
// is cleared of them.
|
||||
const NON_DISCOVERY_ENV_VARS = new Set(['CODEBURN_CACHE_DIR', 'CODEBURN_CURSOR_MAX_BUBBLES', 'KIMI_MODEL_NAME'])
|
||||
|
||||
// Ambient platform paths (set by the OS or desktop session for everyone), not
|
||||
// deliberate user overrides: Windows sets APPDATA and LOCALAPPDATA for every
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue