Skip to content

[Bug]: Local sandbox screenshot previews are unavailable in project chats #176188

Closed

Description

@shakkernerd

Summary

Screenshots created inside a local sandbox can appear as unavailable in the Control UI conversation even when the same files exist in the session's managed project worktree. This prevents people from inspecting their task's screenshots in the reply.

Steps to reproduce

  1. Use a managed project conversation running in a local Docker or Podman sandbox.
  2. Create an image under the sandbox workspace, for example /workspace/.artifacts/proof/screenshot.png.
  3. Return it in an assistant MEDIA:/workspace/.artifacts/proof/screenshot.png directive and open the preview in the owning conversation.

Expected behavior

The preview resolves the sandbox reference to the current file owned by that conversation. Existing message visibility, workspace containment and current-access checks continue to apply.

Actual behavior

The preview is unavailable. The assistant-media route preserves the absolute container path and attempts to open it in the Gateway's host filesystem. Relative workspace references already follow a different resolution path.

Version and evidence

Reproduced against source 976dc6647299dc7437a16cb8c8d0da3e02731bfc with a synthetic image and the real assistant-media HTTP route. The new sandbox-reference case returned HTTP 200 with available: false instead of an available image ticket; the 12 existing route cases passed. The image existed in the session workspace, so capture generation was not the failing step.

Scope

This report concerns local managed project screenshot references in the conversation. It is separate from remote-worker delivery and from the previously fixed host project-root issue #138800. Pending sandbox changes also need the existing workspace settlement behavior before the reader opens the canonical file.

Activity

  1. added
    clawsweeper:intake:bug
    clawsweeper:intake:needs-environment
    P2
    clawsweeper:source-repro
    impact:ux-friction
    issue-rating: 🦞 diamond lobster
    and removed
    clawsweeper:intake:bug
    clawsweeper:intake:needs-environment
    on Oct 18, 2026
  2. clawsweeper commented on Oct 18, 2026

    @clawsweeper
    Contributor

    Codex review: this still needs some work.

    Summary
    This issue identifies a current assistant-media path-resolution defect and is member-authored, so it must remain open for maintainer follow-up.

    Reproducibility: Current source establishes the mismatch: absolute container paths reach the host reader unchanged despite session-workspace policy; the reporter describes a matching HTTP failure, but no runtime reproduction was performed during this review.

    Next step
    Establish a failing assistant-media route regression, then repair session-owned sandbox translation and settlement with Docker and Podman coverage.

    Review details

    Best possible solution:

    Resolve sandbox references through the existing session workspace and settlement owners while preserving media authorization.

    Do we have a high-confidence way to reproduce the issue?

    Current source establishes the mismatch: absolute container paths reach the host reader unchanged despite session-workspace policy; the reporter describes a matching HTTP failure, but no runtime reproduction was performed during this review.

    Is this the best way to solve the issue?

    Repairing reference resolution at the Gateway media boundary fits the existing contract; widening allowed roots or special-casing /workspace would miss workspace settlement and session ownership.

    AGENTS.md: found and applied where relevant.

    Remaining risk / open question:

    • The reported failing route run was not independently executed, and the prepared images concern another issue.
    • Sandbox mapping and pending workspace settlement need boundary coverage to establish that previews serve the current canonical file while preserving message visibility and current-access checks.

    Codex review notes: model internal, reasoning medium; reviewed against 976dc6647299.

    Label changes

    Label changes:

    • add P2: Screenshot previews fail in local sandbox project conversations while the surrounding chat remains usable.
    • add impact:ux-friction: Users cannot inspect existing task screenshots directly from the assistant’s reply.
    • add issue-rating: 🦞 diamond lobster: Current issue advisory state selects this label.
    • add clawsweeper:source-repro: Current issue advisory state selects this label.

    Label justifications:

    • P2: Screenshot previews fail in local sandbox project conversations while the surrounding chat remains usable.
    • impact:ux-friction: Users cannot inspect existing task screenshots directly from the assistant’s reply.
    Evidence reviewed

    What I checked:

    How this review workflow works
    • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
    • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
    • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
    • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
    • Maintainers can also comment @clawsweeper review to request a fresh review only.
    • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge; those execution lanes are retired.
    • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

    Reviewed October 18, 2026, 7:05 AM ET / 11:05 UTC.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2clawsweeper:source-reproimpact:ux-frictionissue-rating: 🦞 diamond lobster

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions