Repository navigation
Description
Failed Model access enablement stays visibly enabled after a fresh disabled readback. Confirmed locally at 44e0dcf254975286c0e9dea443b5cd1ca6b23347.
The page continues to present an active restriction that the backend is not enforcing, even after receiving the authoritative disabled state.
Steps to reproduce:
- Have Model access disabled with a saved default block rule.
- Make the enable request fail, for example with a local backend failure, and turn the Model access switch on.
- After the failure toast, refresh the policy query while keeping the page mounted. The stored config still has enabled=false.
- Compare the switch with a full remount of the page.
Expected: A failed immediate-save toggle must return to the persisted state or clearly remain an unsaved, retryable change. A fresh server response must not be ignored.
Actual: The switch remains on and the rule appears active. saveConfig catches the error without invoking the supplied revert callback; initializedRef prevents later server responses from correcting enabled/mode/rules. A remount finally shows the switch off.
Controls: The real evaluator permits the model under the unchanged disabled config. Remounting the same component with that config correctly shows the switch off. The failure toast is present; the defect is the persistent false state after it.
Source:
- services/platform/app/features/settings/governance/components/model-access-editor.tsx:394-409,422-476
- services/platform/app/features/settings/governance/components/model-access-editor.tsx:505-529
Proof: /Users/yannick/.codex/notes/tale-100-findings/governance-proof/frozen/batch-01/model-access-boundaries.test.tsx. Output: /Users/yannick/.codex/notes/tale-100-findings/governance-proof/frozen/batch-01/batch-01.log. 7/7 fresh probes passed at the pinned SHA.
/Users/yannick/.npm/_npx/22f2fe8d8bc13000/node_modules/.bin/bun x vitest run --config /Users/yannick/.codex/notes/tale-100-findings/governance-proof/vitest.config.ts model-access-boundaries.test.tsx governance-read-errors.test.tsx --maxWorkers=2 --reporter=verboseLocal jsdom execution with real component and save adapter. The final HTTP boundary rejects deterministically and leaves the in-memory saved config unchanged. The actual evaluator checks that config. No real security setting changes.
Deduplication: No matching root in cached all-state issues or current ledger. #2669 is error-message formatting; this proof includes a failure toast and concerns state rollback/readback. Live all-state queries: model access failed save.
Independent review
The parent reran the seven observation tests and controls against the pinned source: 7 passed, exit 0, in 2.93 seconds (governance-proof/parent-batch-01.log). These tests reproduce the current defects; they do not assert a product fix. The parent also checked live all-state GitHub searches and the referenced historical issue bodies.
#2669 concerns error-message formatting. Here the failure toast exists, but the switch continues to present an unpersisted enabled state.
Activity
fix(platform): reconcile model access after failed saves (#4266)