Paths with spaces are not clickable in Codex TUI diff summary

Resolved 💬 2 comments Opened Dec 2, 2025 by Ammaar-Alam Closed Mar 29, 2026

What version of Codex is running?

codex-cli 0.63.0 (built from source at upstream/main commit 32e4a3a4d79b3e8ae000ae8d9ab576438538188a)

What subscription do you have?

n/a (local build for contribution)

Which model were you using?

Not model-specific; reproduced while running local TUI.

What platform is your computer?

Darwin 25.2.0 arm64 arm (uname -mprs)

What issue are you seeing?

When Codex shows a diff summary in the chat transcript, file paths are printed as plain text. If a path contains spaces (e.g., notes with space.txt), the terminal’s auto-linker treats the space as a separator. Cmd/Ctrl-click only opens the first segment ("notes"), so the file cannot be opened from the transcript.

What steps can reproduce the bug?

  1. Create a file with a space in the name (e.g., echo hi > "notes with space.txt").
  2. Ask Codex to edit that file in the TUI (so the transcript shows an "Edited …" block with the filename).
  3. In the transcript, attempt to Cmd/Ctrl-click the file path to open it.

What is the expected behavior?

The entire file path should be clickable/openable even when it contains spaces (e.g., rendered as an OSC-8 hyperlink or otherwise escaped/quoted so the terminal keeps it as one link).

Additional information

  • Observed on macOS Terminal/iTerm2; terminals typically stop links at whitespace unless paths are wrapped in OSC-8 links or quoting. Paths without spaces are unaffected.
  • Likely source: codex-rs/tui/src/diff_render.rs renders paths verbatim via display_path_for without escaping or hyperlink wrapping.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗