Expose settings read and write over RPC#317
Conversation
Implementation PlanAnalysisRPC mode currently has six per-runtime setters ( Codebase findings that shape the design:
DesignTwo new commands, following the established RPC patterns from the session-listing and tree work: 1. Values come from 2.
A single Validation value sets will be defined once (shared constants/type guards next to the DTO in Deliverables
Acceptance criteria
Testing approachNew
Plus one live e2e test in Risks and open questions
Plan created by mach6 |
Vitest coverage
|
Progress UpdateImplemented the full plan — the settings RPC surface is complete. What landed:
Tests: new Verification: build + biome clean, full workspace suite green (pre-commit ran 4010 tests, 0 failed). Smoke-tested against the real binary: snapshot read, exact validation error messages, settings.json written correctly, fresh-process read-back, and corrupt-file loud error (file left untouched) all confirmed. Commit: Progress tracked by mach6 |
Code ReviewCriticalNo critical findings. Important1.
Result: Suggested fix: Drain (and discard) pre-existing errors immediately before the apply phase, so only errors recorded between apply and flush are attributed to this operation. 2. Concurrent RPC input lines are dispatched with Suggested fix: Serialize settings writes (mutex around apply+flush+drain) or use a per-write result channel instead of the shared error list. 3. Settings dispatch only tested by API-key-gated e2e test The only test exercising the actual RPC switch-case wiring ( Suggested fix: Add a dispatch-level test that exercises Suggestions4. "Must be strings" validation branch untested The 5. Partial update preservation of unrelated settings untested No test verifies that a second partial 6. Redundant separate export for The constant is declared as Strengths
Agents run: code-reviewer, error-auditor, test-reviewer, completeness-checker, simplifier Reviewed by mach6 |
Review AssessmentClassifications
Action Plan
Deferred: In-session settings writers ( Assessment by mach6 |
Progress UpdateFixed both genuine review findings (findings 1 and 2 — same root cause: What changed:
Verification: build clean, biome clean, 4013 tests pass (pre-commit), 2555 coding-agent tests pass (22 in settings file). Commit: Progress tracked by mach6 |
Closes #314
Adds a typed settings read/write surface to RPC mode: a
get_settingscommand returning a snapshot of dashboard-relevant persistent defaults, and aset_settingscommand for validated writes to persistent defaults viaSettingsManager— without touching live session state.Implementation plan posted as a comment below.