Skip to content

Add TUI auth profile login flow#122

Merged
shiny-code-bot merged 1 commit into
mainfrom
codex-lab-tui-login-add-account
Jun 17, 2026
Merged

Add TUI auth profile login flow#122
shiny-code-bot merged 1 commit into
mainfrom
codex-lab-tui-login-add-account

Conversation

@shiny-code-bot

Copy link
Copy Markdown
Collaborator

Why

Codex Lab is moving toward daily dogfooding with multiple auth accounts. The existing /login picker could switch among previously-created auth profiles, but adding another account still required leaving the TUI and running a shell command. That made the first multi-auth flow feel unfinished and easy to forget during normal use.

What Changed

  • Makes the /login picker’s Add login... row actionable by pre-filling /login add in the composer.
  • Adds /login add <profile> to validate a new profile name, reject ambiguous names such as default, switch to that profile’s auth_home, and start the ChatGPT browser login flow.
  • Tracks the pending profile login by login_id, surfaces login failure, and records auth-profile metadata only after the post-login AccountUpdated notification confirms the app server has reloaded auth.
  • Clears stale pending profile-login state before later auth-profile switches so unrelated account updates cannot create phantom profile metadata.

Verification

  • cargo test -p codex-tui login_slash_command
  • cargo check -p codex-tui

@shiny-code-bot shiny-code-bot merged commit b3fb058 into main Jun 17, 2026
6 checks passed
@shiny-code-bot shiny-code-bot deleted the codex-lab-tui-login-add-account branch June 17, 2026 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant