Files
codex/codex-rs/tui
Charlie Marsh 3c7ae4a812 Scope TUI app directory state to the active context (#38743)
## Why

App directory data and in-flight requests can outlive the account, workspace, or thread that produced them, allowing stale apps to appear in the current TUI context.

## What changed

- Invalidate cached app data, dismiss the app picker, and start a fresh fetch when the account, workspace, or thread changes.
- Tag app directory fetches with their originating thread, workspace, and scope generation, and ignore queued requests or results that no longer match.
- Treat `AppListUpdated` notifications as revalidation signals instead of directly adopting their unscoped contents, with deduplication and a bounded error retry.

## Testing

Added coverage for stale request and result rejection, context invalidation, picker dismissal, and notification revalidation.

GitOrigin-RevId: f20930a0598a6abbdfb3c7826ec955346fe2da7a
2026-08-15 10:57:15 +00:00
..