You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: server removal is not atomic with the config commit; a pending removal can be resurrected by any later save #1559
Removing a server is not part of the config commit protocol, and a pending (async) removal can be undone by any later save:
REST removal (Server.RemoveServer, internal/server/server.go:2153-2240) removes the client and storage row first and only then calls SaveConfiguration (takes configCommitMu), while the live config still lists the server. A concurrent LoadConfiguredServers in that gap re-creates the deleted storage row (lifecycle.go:1557) and reconnects it; the removal's own save then republishes the recreated row. A successful DELETE leaves the server configured and possibly running.
Config-driven removal is asynchronous (lifecycle.go:1613-1640): cleanup runs later in a goroutine. If an unrelated commit (add/toggle of server B -> SaveConfiguration, :1667) happens before cleanup, SaveConfiguration rebuilds the server list from storage and republishes A into runtime config and disk. A then looks "configured" again, the cleanup guard/skip logic cancels the removal, and A stays configured/persisted despite the successful removal.
A delayed sync that resumes after such a resurrection reconciles against the resurrected config, so A is never even scheduled for removal.
Failure scenario
Apply a config removing A, delay cleanup, add B (save republishes A from storage), release cleanup: A remains in storage, runtime config, disk and the manager.
Suggested direction
Introduce a single removal commit (under configCommitMu: drop from live config, delete storage row, retire client) used by REST, MCP and config-driven paths, plus a pending-removal tombstone that SaveConfiguration/reconcile/supervisor respect until cleanup finishes, while still allowing a deliberate re-add. Tests: gate cleanup, add B, release; REST removal paused after storage delete while reconcile runs.
Found by OpenCode Sol 6.1 cross-model review of the (now split) oversized PRs #1553 (UX-01) and #1555 (UX-02); verified still present on origin/main (704795c) by reading the cited sites. Pre-existing, deliberately out of scope of the minimal core PRs. Review transcripts: docs/qa/0.70.0-ux-2026-10-10/remediation/reviews/.
Activity
docs(specs): Spec 116: config commit consistency, atomic removal and …
fix: single config commit section with per-server generations (Spec 1…
fix: atomic server removal with full purge and per-server incarnation…