Summary
In Codex CLI 0.136.0, a bare URL containing ~ in the path is rendered/linkified only up to the ~. The rest of the URL is displayed as plain text, so Cmd-click opens an incomplete URL.
This appears to be in the Codex CLI presentation layer rather than the terminal's native URL detection. The same terminal correctly recognizes the full URL when the URL is printed by a normal shell command outside Codex.
Repro
-
Run Codex CLI in the interactive TUI.
-
Have the assistant output this bare URL:
https://www.cs.tufts.edu/~nr/cs257/archive/olin-shivers/dissertation.pdf
-
Observe the rendered URL in the Codex output.
-
Cmd-hover or Cmd-click the URL.
Actual behavior
Only the portion before the tilde appears to be recognized as a link:
https://www.cs.tufts.edu/
The suffix is not included in the clickable destination:
~nr/cs257/archive/olin-shivers/dissertation.pdf
Cmd-click therefore opens the wrong/incomplete URL.
Expected behavior
The full URL should be recognized and opened:
https://www.cs.tufts.edu/~nr/cs257/archive/olin-shivers/dissertation.pdf
~ is valid in a URL path, so it should not terminate link detection.
Terminal cross-check
The terminal itself handles the full URL correctly outside Codex. Copying the same URL into an echo command in another terminal window does not underline by default, but when hovering while holding Cmd it recognizes the full URL and opens the full URL in the browser when clicked.
That suggests this is either in Codex CLI's rendering/linkification path or in how Codex emits styled/hyperlink spans, not in the terminal's URL parser.
Environment
- Codex CLI:
codex-cli 0.136.0
- OS: macOS / Darwin arm64
- Terminal environment observed by Codex:
TERM=xterm-256color
TERM_PROGRAM=zed
- shell:
/opt/homebrew/bin/bash
gh: 2.86.0
Related issues
Possibly related but not identical:
This report is specifically about bare URL linkification stopping at ~ in a URL path.
Summary
In Codex CLI
0.136.0, a bare URL containing~in the path is rendered/linkified only up to the~. The rest of the URL is displayed as plain text, so Cmd-click opens an incomplete URL.This appears to be in the Codex CLI presentation layer rather than the terminal's native URL detection. The same terminal correctly recognizes the full URL when the URL is printed by a normal shell command outside Codex.
Repro
Run Codex CLI in the interactive TUI.
Have the assistant output this bare URL:
Observe the rendered URL in the Codex output.
Cmd-hover or Cmd-click the URL.
Actual behavior
Only the portion before the tilde appears to be recognized as a link:
The suffix is not included in the clickable destination:
Cmd-click therefore opens the wrong/incomplete URL.
Expected behavior
The full URL should be recognized and opened:
~is valid in a URL path, so it should not terminate link detection.Terminal cross-check
The terminal itself handles the full URL correctly outside Codex. Copying the same URL into an
echocommand in another terminal window does not underline by default, but when hovering while holding Cmd it recognizes the full URL and opens the full URL in the browser when clicked.That suggests this is either in Codex CLI's rendering/linkification path or in how Codex emits styled/hyperlink spans, not in the terminal's URL parser.
Environment
codex-cli 0.136.0TERM=xterm-256colorTERM_PROGRAM=zed/opt/homebrew/bin/bashgh:2.86.0Related issues
Possibly related but not identical:
This report is specifically about bare URL linkification stopping at
~in a URL path.