Repository navigation
docs(adr): ADR-0007 D6 — a null clear of an env-pinned key is not refused (#30385) - #30698
Conversation
…used Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Utp6CaQzHSoRvseiSpfmLn
|
domain:server#2 · os-bill · session_01Utp6Cbvcmv8YWFhFJwzjKL Contract-review-claim: session_01Utp6Cbvcmv8YWFhFJwzjKL · head 26da6f2 · 2026-11-05T22:42Z |
|
domain:server#2 · os-bill · session_01Utp6Cbvcmv8YWFhFJwzjKL Contract reviewServed-tier: Inputs read: card #30385 body and all 8 comments (triage 6653992606, claim 6654828319, dev report 6657238833, ruling 6670154789, release 6670837769, re-claim 6671137072, ADR dev report 6671431750); PR #30698 body, file list (1 file) and net diff against ① Derived judgments
② Semver levelRight. Docs-only diff under ③ Boundary flags
④ Design judgmentFile: The three edits say what the code does, in the words the ruling prescribes, and nothing the code does not do: only
Must-fix: none. Should-fix 1 — the ADR still states the old rule twice, unqualified. The architecture sketch (line 86, " Should-fix 2 — D6's "is not refused" is broader than the code. The clear is not refused by the env pin; the Phase 2 row locks and the write predicates still judge it, and the pins in Should-fix 3 — the anchor the ruling named. Ruling 6670154789 item 3 ordered the amendment "with its Implemented-by: VERDICT: PASS |
…ption to the pin, anchor settings-service Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Utp6CaQzHSoRvseiSpfmLn
|
domain:server#2 · os-bill · session_01Utp6Cbvcmv8YWFhFJwzjKL Contract reviewDelta-of: 6671549520 Delta review: one commit, Inputs read: comment 6671549520 in full; the PR body and comment list at the new head; ① Derived judgments
② Semver levelUnchanged from 6671549520. The delta adds one JSON file under ③ Boundary flags
④ Design judgmentFile: The three ADR hunks close the two precision gaps 6671549520 named without opening a new one: no sentence in the record now says more than the code does (the clear is judged by locks and predicates) or less (the sketch and the interface comment carry the exception). The anchor earns its failure mode in the README's sense — a reader of the pre-flight alone could "fix" Must-fix: none. Should-fix 1 — give ADR-0007's principles a machine-readable decision index on a later touch. Because the record declares no Implemented-by: VERDICT: PASS |
|
domain:server#2 · os-bill · session_01Utp6Cbvcmv8YWFhFJwzjKL 维护者速读
席位核对 — ACCEPT · domain:server#2 · head
|
Requested by Bill · project thread
domain:server#2 · os-bill · session_01Utp6Cbvcmv8YWFhFJwzjKL
维护者速读
null),行锁和写入规则照常判」;REST 表 409 一栏、架构草图和服务接口注释各加同样的例外;新增一个 ADR 锚点文件,把settings-service.ts钉到 ADR-0007。docs/adr/0007-settings-manifest-and-kv-store.md第 3 行、第 86 行、第 101 行(D6)、第 303 行、第 323 行(REST 表),以及新锚点文件。node scripts/check-adr-links.mjs && pnpm check:adr-anchors && pnpm check:adr-index,预期全绿。Refs #30385
Clause-②: no
Metadata-protocol: none
What changes
ADR-0007 D6 said every UI write to an env-pinned key is refused with HTTP 409
locked-by-env. PR #30448 lets exactly one write through the pin: a clear (null/ absent), which nulls the stored row beneath the override. The value in force does not move — the resolver still answerssource='env', locked=true— and every other write stays 409 (settings-service.tspre-flight:const clears = patch[key] === null || typeof patch[key] === 'undefined'; if (!clears && this.effectiveEnvOverride(...)) throw new SettingsLockedError(...)).Per AGENTS.md (a decision change amends the original ADR's status line), and per contract review 6671549520's three should-fixes:
· **Amended (2026-11-05, #30385)** — D6: a clear (null) of an env-pinned key is not refused; it clears the stored value beneath the override and changes nothing in force.PUT /api/settings/:namespacerow:(409 if any key locked-by-env, except a null clear).(a null clear excepted — D6), so the ADR does not contradict D6.Out of scope (known drift, untouched):
resetNamespacewording (reset still skips pinned keys; widening it is #30664), D-tier drift, env-var prefixes.ADR anchor
New
scripts/adr-anchors/packages__services__service-settings__src__settings-service.ts.json(ADR-0007), as ruling 6670154789 item 3 names. Its invariant: an env override in force refuses every write but a clear; the clear nulls the stored row and changes nothing in force.settings-service.tsalready cites ADR-0007 onmain, sopnpm check:adr-anchorsis green onmainand on this branch.Verification
At head
27a3e1c9: derived gates for the two files, 29 of 29 exit 0;--ranreconcile 0 NOT-MEASURED. The first head (26da6f27) ran 21 of 21. Contract review PASS 6671549520 on the first head; the delta review covers the fix commit.No changeset: docs/adr only (
skip-changeset).