Allow sign in via link instead of trying to use XDG to open a system browser
Resolved 💬 3 comments Opened May 17, 2025 by bossdown123 Closed Aug 7, 2025
Sign in with ChatGPT to generate an API key or paste one you already have.
[use arrows to move, enter to select]
❯ Sign in with ChatGPT
Paste an API key (or set as OPENAI_API_KEY)
( ● ) Waiting for authentication… ctrl + c to quit
node:events:485
throw er; // Unhandled 'error' event
^
Error: spawn xdg-open ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21)
Emitted 'error' event on ChildProcess instance at:
at ChildProcess._handle.onexit (node:internal/child_process:292:12)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
errno: -2,
code: 'ENOENT',
syscall: 'spawn xdg-open',
path: 'xdg-open',
spawnargs: [
''
]
}```
should have an option to just click a link instead
3 Comments
I encountered this limitation while using Codex in a devcontainer without
xdg-utilsinstalled. But VS Code provides a helper to open the host system's browser, which you can hook up like so:thanks this works
Thank you for the feedback! Please try the latest version of Codex CLI to see if the issue persists. If it does, we'd appreciate a report or a PR to the
codex-rs/implementation. More details on our project update can be found here.