feat(parity): CI-enforced multi-surface parity harness#591
Merged
Conversation
With CLI, TUI, and GUI sharing one core, parity drift is now a build failure instead of a thing to remember: - internal/parity derives the TUI's capability surface mechanically from ui.KeyMap (every exported key.Binding field is an action) - every action must be covered in desktop/capabilities.json or explicitly skipped in parity-ignore.json with a written reason — uncovered actions fail CI with instructions - capabilities may declare the API routes they use; these are verified against the routes registered in internal/web/server.go (parsed via AST), so the manifest can't reference endpoints that don't exist - stale covers/ignores (actions that no longer exist) also fail, so the files can't rot Current state encoded honestly: Routines is an acknowledged ignore (GUI view not built yet); SpotlightSync and ToggleShellPane are deliberate non-goals with reasons. AGENTS.md codifies the rule: a feature isn't done until its logic lives below internal/ui and is reachable through the API. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes CLI/TUI/GUI parity drift a build failure instead of a thing to watch for.
How it works
ui.KeyMap— every exportedkey.Bindingfield is a user-facing action (38 today). No manual list to forget to update.desktop/capabilities.jsonor explicitly ignored inparity-ignore.jsonwith a written reason. An uncovered action fails CI with instructions:"api": ["POST /api/tasks/{id}/execute"]); these are verified against the routes actually registered ininternal/web/server.go(AST-parsed). The manifest can't reference endpoints that don't exist — and deleting a route the GUI depends on fails too.Runs as a plain
go testin the existing Test job — no new CI wiring.Current state, encoded honestly
Routines→ ignored with a dated reason (GUI view not built yet; needs/api/routinesfirst). Removing the ignore entry is the signal the gap closed.SpotlightSync,ToggleShellPane→ deliberate non-goals with reasons (the GUI terminal shows the whole tmux window; Spotlight export is local-indexing).AGENTS.md codifies the underlying rule: a feature isn't done until its logic lives below
internal/uiand is reachable through the API — UIs are thin views.Both failure modes verified by mutation (removed an ignore → gap failure; pointed a capability at a fake route → route failure).
🤖 Generated with Claude Code