Codex Desktop SSH remote PDF preview fails for valid PDFs slightly above 1 MiB

Open 💬 0 comments Opened Jul 3, 2026 by yoshi-19zo

Summary

In Codex Desktop connected to an SSH remote workspace, PDF preview fails for valid PDFs slightly above 1 MiB. Smaller PDFs preview correctly, PNG previews work, and the same PDFs are valid according to standard PDF tools.

Environment

  • Codex Desktop on macOS
  • SSH remote workspace
  • Remote Codex CLI: codex-cli 0.142.5
  • Tested against two separate SSH remote hosts with the same behavior

Observed behavior

The PDF preview pane shows a generic preview failure message:

This preview could not be loaded

In my localized UI the message was:

このプレビューを読み込めませんでした

No explicit size-limit message is shown.

Reproduction

On an SSH remote workspace, create valid PDF 1.4 files with different sizes and open them from Codex Desktop's PDF preview.

Observed threshold:

  • Opens: minimal_padded_1024kib.pdf
  • size: 1,048,576 bytes
  • PDF 1.4, 1 page, not encrypted
  • Fails: minimal_padded_1050kib.pdf
  • size: 1,075,200 bytes
  • PDF 1.4, 1 page, not encrypted

A normal report/research PDF around 3.2 MB also fails in the same remote workspace.

Validation

The failing PDFs are valid outside Codex preview:

  • pdfinfo: OK
  • pdftoppm: renders pages to PNG successfully
  • Ghostscript: gs -q -dNOPAUSE -dBATCH -sDEVICE=nullpage file.pdf exits 0
  • Python pypdf: reports expected page count and is_encrypted=False
  • macOS Preview opens the copied PDF normally
  • Codex can display PNGs rendered from the PDF

Expected behavior

Codex Desktop should preview valid PDFs from SSH remote workspaces above 1 MiB, or show a clear size/transfer limit error if there is an intentional limit.

Notes

This seems distinct from the local 10 MB preview-size limit. The failing remote PDF is only slightly above 1 MiB, and the UI does not show a "file too large" message.

Possibly related:

  • #29125
  • #26805
  • #29779

If this should be tracked under an existing remote-preview issue, feel free to close as duplicate. I opened this because it has a minimal size-threshold reproduction.

View original on GitHub ↗