From c29afc0cf3d396d67f0926e2f32f9035ad894392 Mon Sep 17 00:00:00 2001 From: Matthew Zeng Date: Mon, 5 Jan 2026 13:46:42 -0800 Subject: [PATCH] [device-auth] Update login instruction for headless environments. (#8753) We've seen reports that people who try to login on a remote/headless machine will open the login link on their own machine and got errors. Update the instructions to ask those users to use `codex login --device-auth` instead. CleanShot 2026-01-05 at 11 35 02@2x --- codex-rs/tui/src/onboarding/auth.rs | 6 ++++++ codex-rs/tui2/src/onboarding/auth.rs | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/codex-rs/tui/src/onboarding/auth.rs b/codex-rs/tui/src/onboarding/auth.rs index 6307e6e7d..9de8fd170 100644 --- a/codex-rs/tui/src/onboarding/auth.rs +++ b/codex-rs/tui/src/onboarding/auth.rs @@ -279,6 +279,12 @@ impl AuthModeWidget { lines.push("".into()); lines.push(Line::from(state.auth_url.as_str().cyan().underlined())); lines.push("".into()); + lines.push(Line::from(vec![ + " On a remote or headless machine? Use ".into(), + "codex login --device-auth".cyan(), + " instead".into(), + ])); + lines.push("".into()); } lines.push(" Press Esc to cancel".dim().into()); diff --git a/codex-rs/tui2/src/onboarding/auth.rs b/codex-rs/tui2/src/onboarding/auth.rs index 6307e6e7d..9de8fd170 100644 --- a/codex-rs/tui2/src/onboarding/auth.rs +++ b/codex-rs/tui2/src/onboarding/auth.rs @@ -279,6 +279,12 @@ impl AuthModeWidget { lines.push("".into()); lines.push(Line::from(state.auth_url.as_str().cyan().underlined())); lines.push("".into()); + lines.push(Line::from(vec![ + " On a remote or headless machine? Use ".into(), + "codex login --device-auth".cyan(), + " instead".into(), + ])); + lines.push("".into()); } lines.push(" Press Esc to cancel".dim().into());