Skip to content

Opening the editor essentially deletes pasted content #4015

@maxandron

Description

@maxandron

Description

Hello!

I believe this issue existed before the v1 releases as well.
If after pasting content (and seeing [Pasted ~11 lines]), I open the editor - the content in the editor shows the summary ([Pasted ~11 lines]).

There are two separate issues here:
a. I don't have any option to expand or edit pasted content
b. If I edit something else in the editor and close it, the pasted content summary becomes plain text of "[Pasted ~11 lines]" and does not expand to the pasted lines when sending the prompt.

Same thing is happening with images, though of course, the handling should be different

I'm happy to try taking a crack at it.

OpenCode version

v1.0.37

Steps to reproduce

  1. Paste enough content for a summary to occur / paste an image
  2. Open editor with -e
  3. Save an close the editor
  4. Send the prompt
  5. Note that the LLM didn't receive the text/image

Screenshot and/or share link

Image

Operating System

macOS 26.0.1

Terminal

tmux in ghostty

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingopentuiThis relates to changes in v1.0, now that opencode uses opentui

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions