warpdotdev/warp · error · anyhow::Error

GitHub authorization expired. Please try again.

Error message

GitHub authorization expired. Please try again.

What it means

Terminal error from the OAuth polling branch: the authorization transaction expired (OauthConnectTxStatus::Expired) before reaching a terminal Completed/Failed state. The browser auth URL was opened and polling started, but the transaction's server-side lifetime elapsed without the user finishing authorization, so the create/update is aborted with a retry hint.

Source

Thrown at app/src/ai/agent_sdk/environment.rs:657

                                poll_future,
                                move |_, poll_result, ctx| {
                                    match poll_result {
                                        Ok(OauthConnectTxStatus::Completed) => {
                                            // OAuth completed, retry auth check and operation.
                                            Self::auth_repos_then_execute(repos, next_attempt, operation_name, on_success, ctx);
                                        }
                                        Ok(OauthConnectTxStatus::Failed) => {
                                            ctx.terminate_app(
                                                warpui::platform::TerminationMode::ForceTerminate,
                                                Some(Err(anyhow::anyhow!(
                                                    "GitHub authorization failed. Please try again."
                                                ))),
                                            );
                                        }
                                        Ok(OauthConnectTxStatus::Expired) => {
                                            ctx.terminate_app(
                                                warpui::platform::TerminationMode::ForceTerminate,
                                                Some(Err(anyhow::anyhow!(
                                                    "GitHub authorization expired. Please try again."
                                                ))),
                                            );
                                        }
                                        Ok(OauthConnectTxStatus::Pending)
                                        | Ok(OauthConnectTxStatus::InProgress) => {
                                            // Should not be returned by poll_oauth_until_terminal.
                                            ctx.terminate_app(
                                                warpui::platform::TerminationMode::ForceTerminate,
                                                Some(Err(anyhow::anyhow!(
                                                    "Unexpected non-terminal OAuth status returned"
                                                ))),
                                            );
                                        }
                                        Err(err) => {
                                            ctx.terminate_app(
                                                warpui::platform::TerminationMode::ForceTerminate,
                                                Some(Err(anyhow::anyhow!(

View on GitHub (pinned to e72fd7aacb)

Solutions

  1. Re-run the command and complete the GitHub authorization promptly after the browser opens
  2. Authorize immediately when the URL appears — the transaction window is limited
  3. Pre-authorize by installing/granting the GitHub App access before running create, so the check passes without the interactive flow
  4. Keep the session alive (no sleep/suspend) between CLI start and browser consent
Defensive patterns

Strategy: retry

Validate before calling

// Reduce reliance on the timed flow: pre-install and pre-grant the GitHub App
// so check_user_repo_auth_status passes without an interactive transaction.

Try / catch

Ok(OauthConnectTxStatus::Expired) => {
    // transaction TTL elapsed: re-run the command and finish consent promptly
}

Prevention

When it happens

Trigger: Opening the auth URL but not completing GitHub consent before the transaction TTL expires — user walks away, the browser tab is left idle, or the flow is started and interrupted; also slow hand-offs between CLI and browser.

Common situations: Stepping away mid-authorization; only noticing the browser tab minutes later; slow GitHub SSO approval chains; small screens/notifications hiding the consent page.

Related errors


AI-assisted analysis of warpdotdev/warp@e72fd7aacb (2026-08-16). Data as JSON: /api/errors/8620716b564d271c. Report an issue: GitHub.