Repository navigation
fix(auth): make Codex logout recovery actionable - #130866
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
obviyus
force-pushed
the
codex/auth-recovery-actions
branch
from
August 27, 2026 09:53
9a28a91 to
c737d90
Compare
Collaborator
Author
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Aug 28, 2026
Hard OpenAI OAuth failures now offer one shared login action across normal replies, returned provider errors, fallback summaries, Control UI guidance, and automation alerts. OAuth mode survives failure aggregation so API-key failures never receive the Codex pairing action. Co-authored-by: Ayaan Zaidi <[email protected]>
This was referenced Nov 15, 2026
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.
Problem
Hard OpenAI OAuth failures had split recovery ownership. Automation alerts carried a Log in to Codex action, while normal turns, returned provider errors, Control UI turns, and later retries showed text-only failures. Later retries also lost the credential mode after an OAuth profile entered permanent auth cooldown.
Root cause
authMode, so later disabled-profile errors could not safely distinguish OAuth from API-key auth.rawError, but the OAuth classifier only followedcause.Fix
/login codexbutton.rawErrormetadata.Security
Proof
/login codexaction, received generic refresh text;c737d903364: patch correct, zero findings, security cleared, no maintainer decision, and no rank-up moves.Telegram Test Server E2E
main, owner DM: one provider request produced text-only auth failure and no callback button.c737d903364, owner DM: the failed turn showed Log in to Codex; the real callback click completed; a private OpenAI device-code prompt arrived.c737d903364, group: the failed turn showed the same button; clicking it returned DM-only guidance; zero device-code messages appeared in the group.ok: true.Codex contract
../codex/codex-rs/login/src/auth/manager.rs:1614-1665treats invalidated refresh tokens as permanent and revoked.../codex/codex-rs/login/src/device_code_auth.rs:149-178,181-232owns the explicit 15-minute device prompt, token exchange, validation, and persistence.Change size