Feedback ID
019ef11e-95ba-72c3-a85d-518dfcbd47b0
Summary
When a Nightly/nteract MCP tool returns a notebook cell with an image/png display output, the Codex MCP Apps/tool-result iframe renders as a blank white output area. The same PNG exists and can be copied/exported from the MCP Apps view, so the issue appears specific to rendering inside the Codex MCP Apps iframe, not notebook execution or clipboard.
Repro
- In Codex desktop, use the nteract Nightly MCP tools.
- Attach to a Python notebook and run a cell that produces a Matplotlib/Seaborn PNG.
- The tool result structured content includes a display output with
image/png pointing at a local blob URL like http://localhost:<port>/blob/<sha256> and blob_base_url like http://localhost:<port>.
- Expand/view the MCP Apps rendered output in Codex.
- Expected: the PNG appears in the app iframe.
- Actual: the iframe/tool card is blank/white, although the image can be copied/exported from elsewhere.
Local evidence
- nteract maps blob URLs under
blob_base_url into content refs and resolves them through createMcpAppBlobResolver.
- The nteract output-frame CSP is already permissive for static raster outputs, including
img-src * data: blob: and connect-src *, so the nteract output document CSP does not look like the blocking layer.
- The Codex MCP app renderer only uses the daemon output document URL when
hostCapabilities.sandbox.csp.frameDomains allows the daemon blob origin. Otherwise daemonOutputFrameUrl(...) returns null and the renderer falls back to srcdoc.
- The relevant source behavior is covered by the Codex app test for shared cell outputs: including
http://localhost:47830 in frameDomains yields outputDocumentUrl: http://localhost:47830/output-frame; excluding it forces outputDocumentUrl: null.
- Local macOS logs did not expose a clear browser-console CSP violation, so this is inferred from the source path and the observed blank iframe.
Suggested fix
For MCP Apps that receive structured content with blob_base_url on loopback, Codex should advertise/allow the dynamic loopback origin in the app host sandbox capabilities and outer iframe CSP, including at least:
frame-src / host capability frameDomains for http://localhost:<blob-port> or a safe loopback wildcard.
- Image/fetch access for
http://localhost:<blob-port>/blob/....
- Nested frame access to
http://localhost:<blob-port>/output-frame when the app asks for it.
If Codex intentionally does not allow local loopback frame/image fetches from MCP Apps, it would help for the host capability to make that explicit so apps like nteract can switch to inline data:image/png;base64,... for static raster outputs.
Feedback ID
019ef11e-95ba-72c3-a85d-518dfcbd47b0
Summary
When a Nightly/nteract MCP tool returns a notebook cell with an
image/pngdisplay output, the Codex MCP Apps/tool-result iframe renders as a blank white output area. The same PNG exists and can be copied/exported from the MCP Apps view, so the issue appears specific to rendering inside the Codex MCP Apps iframe, not notebook execution or clipboard.Repro
image/pngpointing at a local blob URL likehttp://localhost:<port>/blob/<sha256>andblob_base_urllikehttp://localhost:<port>.Local evidence
blob_base_urlinto content refs and resolves them throughcreateMcpAppBlobResolver.img-src * data: blob:andconnect-src *, so the nteract output document CSP does not look like the blocking layer.hostCapabilities.sandbox.csp.frameDomainsallows the daemon blob origin. OtherwisedaemonOutputFrameUrl(...)returnsnulland the renderer falls back tosrcdoc.http://localhost:47830inframeDomainsyieldsoutputDocumentUrl: http://localhost:47830/output-frame; excluding it forcesoutputDocumentUrl: null.Suggested fix
For MCP Apps that receive structured content with
blob_base_urlon loopback, Codex should advertise/allow the dynamic loopback origin in the app host sandbox capabilities and outer iframe CSP, including at least:frame-src/ host capabilityframeDomainsforhttp://localhost:<blob-port>or a safe loopback wildcard.http://localhost:<blob-port>/blob/....http://localhost:<blob-port>/output-framewhen the app asks for it.If Codex intentionally does not allow local loopback frame/image fetches from MCP Apps, it would help for the host capability to make that explicit so apps like nteract can switch to inline
data:image/png;base64,...for static raster outputs.