Skip to content

Remove core protocol dependency [1/2]#20324

Merged
etraut-openai merged 7 commits into
mainfrom
etraut/tui-cleanup-pass2-1
Apr 30, 2026
Merged

Remove core protocol dependency [1/2]#20324
etraut-openai merged 7 commits into
mainfrom
etraut/tui-cleanup-pass2-1

Conversation

@etraut-openai

@etraut-openai etraut-openai commented Apr 30, 2026

Copy link
Copy Markdown
Collaborator

Why

This stack moves codex-tui away from the core protocol event surface and toward app-server API shapes plus TUI-owned local models. This first PR sets up the lower-risk foundation: it introduces the local model surface and extracts app-server event routing into focused TUI modules while preserving the existing behavior for the larger migration in PR2.

This PR is part 1 of a 2-PR stack:

  1. Add TUI-owned replacement models and extract app-server event routing.
  2. Move the active TUI flow to app-server notifications and delete obsolete adapter code.

What changed

  • Added TUI-owned approval, diff, session state, session resume, token usage, and user-message models.
  • Added app/app_server_event_targets.rs and app/app_server_events.rs to hold app-server event targeting and dispatch logic outside app.rs.
  • Updated app/status tests to use the local model layer and added focused routing coverage.
  • Boxed a few large async TUI test futures so this base layer remains checkable without overflowing the default test stack.

Verification

  • cargo check -p codex-tui --tests

@etraut-openai etraut-openai force-pushed the etraut/tui-cleanup-pass2-1 branch from dc41aab to e9eaab1 Compare April 30, 2026 05:23
@etraut-openai etraut-openai changed the title Remove core protocol dependency [1/10] Remove core protocol dependency [1/5] Apr 30, 2026
@etraut-openai etraut-openai force-pushed the etraut/tui-cleanup-pass2-1 branch from e9eaab1 to d57635e Compare April 30, 2026 06:54
@etraut-openai etraut-openai changed the title Remove core protocol dependency [1/5] Remove core protocol dependency [1/2] Apr 30, 2026
@fcoury-oai fcoury-oai self-assigned this Apr 30, 2026

@fcoury-oai fcoury-oai left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ran a focused local smoke test for the TUI refactor path on this PR: started the PR branch’s TUI in a disposable workspace, exercised a normal read-only turn, an approval-backed file edit through the patch/diff UI, the /status surface, and a resume flow.

Everything worked as expected. Code looks good, approved.

@etraut-openai etraut-openai merged commit c70cdc1 into main Apr 30, 2026
62 of 73 checks passed
@etraut-openai etraut-openai deleted the etraut/tui-cleanup-pass2-1 branch April 30, 2026 17:52
@github-actions github-actions Bot locked and limited conversation to collaborators Apr 30, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants