{"record":{"id":"6add01871021f924","repo":"warpdotdev/warp","slug":"timed-out-waiting-for-oauth-authorization","errorCode":null,"errorMessage":"Timed out waiting for OAuth authorization","messagePattern":"Timed out waiting for OAuth authorization","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"app/src/ai/agent_sdk/oauth_flow.rs","lineNumber":46,"sourceCode":"        let status = integrations_client\n            .poll_oauth_connect_status(tx_id.clone())\n            .await?;\n\n        match status {\n            OauthConnectTxStatus::Completed\n            | OauthConnectTxStatus::Failed\n            | OauthConnectTxStatus::Expired => {\n                return Ok(status);\n            }\n            OauthConnectTxStatus::Pending | OauthConnectTxStatus::InProgress => {\n                if attempt % 5 == 0 {\n                    log::debug!(\"Still waiting for authorization... ({attempt}/{MAX_ATTEMPTS})\",);\n                }\n            }\n        }\n    }\n\n    Err(anyhow!(\"Timed out waiting for OAuth authorization\"))\n}\n","sourceCodeStart":28,"sourceCodeEnd":48,"githubUrl":"https://github.com/warpdotdev/warp/blob/e72fd7aacbbb2236d9b3be2aad7e7178fe94b4bc/app/src/ai/agent_sdk/oauth_flow.rs#L28-L48","documentation":"poll_oauth_until_terminal polls the OAuth connect transaction every 5 seconds for up to 120 attempts (10 minutes total). If the status never leaves Pending/InProgress within that window, it gives up with this error. Terminal statuses (Completed/Failed/Expired) return normally — only a permanently pending transaction times out.","triggerScenarios":"Provider or integration setup where the user opens the connect URL but never completes authorization within 10 minutes, authorizes in a different browser/identity so the transaction stays pending, or closes the tab and walks away.","commonSituations":"User steps away mid-flow; SSO/email login friction during consent; the transaction expiring server-side while the client keeps seeing Pending; user authorizing with a different account than intended.","solutions":["Re-run the setup command — each run generates a fresh transaction and URL","Complete the browser authorization promptly after the URL is printed","Make sure you authorize with the intended account (team vs personal context)","Verify the CLI can reach the server for status polling (network/proxy)"],"exampleFix":"# before\nwarp provider setup github --team   # user never finishes browser consent -> timeout\n\n# after (re-run and complete promptly)\nwarp provider setup github --team   # fresh URL; authorize within 10 minutes","handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"for i in 1 2; do\n  out=$(warp provider setup \"$slug\" --team 2>&1) && { echo \"$out\"; exit 0; }\n  case \"$out\" in *'Timed out waiting for OAuth authorization'*) echo 'retrying with a fresh URL' >&2;; *) echo \"$out\" >&2; exit 1;; esac\ndone\nexit 1","preventionTips":["Complete browser authorization immediately after the URL prints","Authorize in the same browser/profile where you are logged into the intended account","Treat a 10-minute timeout as 'restart the flow', not 'keep waiting'"],"tags":["oauth","timeout","provider","integration"],"backgroundTag":null,"analyzedSha":"e72fd7aacbbb2236d9b3be2aad7e7178fe94b4bc","analyzedAt":"2026-08-16T08:27:25.381Z","schemaVersion":2},"datasetVersion":"2026-08-16T13:17:31.715Z"}