Skip to content

Desktop freezes or crashes when pasting large text into the prompt input #47425

Closed as not planned

Description

@hufangyuan460-blip

Description

Bug description

The OpenCode desktop app crashes immediately when a large amount of text is pasted directly into the prompt input on Windows.

Context

I first encountered this issue while developing a Spring Boot project. After the project failed at runtime, I copied the error logs from IntelliJ IDEA and pasted them directly into OpenCode to ask for help analyzing the problem. The application crashed immediately after pasting the logs.

I then performed controlled tests using plain-text files containing only the character 1:

  • Around 50,000 characters: significant UI lag
  • Around 150,000 characters: consistently triggers an out-of-memory crash

Reproduction steps

  1. Download the attached large text file, which contains approximately 150,000 repetitions of the character 1.
  2. Open the file and copy all of its content.
  3. Open OpenCode Desktop on Windows.
  4. Paste the copied content directly into the prompt input.
  5. Observe that the application crashes.

The issue can also be observed in a real-world scenario:

  1. Open a Spring Boot project in IntelliJ IDEA on Windows.
  2. Run the project until a runtime error occurs.
  3. Copy the error logs from the Run console.
  4. Paste the logs directly into the OpenCode desktop prompt input.

Observed behavior

  • Pasting around 50,000 characters causes significant UI lag.
  • Pasting around 150,000 characters consistently triggers an out-of-memory crash.
  • In the original scenario, pasting Spring Boot runtime error logs caused an immediate crash.

Expected behavior

Large pasted content should not crash or block the application. It could be automatically converted into a .txt attachment or handled through another non-blocking mechanism.

Environment

  • OS: Windows 10
  • App: OpenCode Desktop 1.18.27
  • Source of text: IntelliJ IDEA Spring Boot runtime error logs
  • Controlled test input: approximately 150,000 repetitions of the character 1

Plugins

No response

OpenCode version

1.18.27

Steps to reproduce

Reproduction steps

  1. Download the attached large-paste-test.txt file.
  2. Open the file and copy all of its content.
  3. Open OpenCode Desktop on Windows.
  4. Paste the copied content directly into the prompt input.
  5. Observe the application behavior.

The attached file contains approximately 140,000 characters. It consistently reproduces the crash in my environment.

large-paste-test.txt

Screenshot and/or share link

Image

Operating System

Windows10

Terminal

No response

Activity

  1. github-actions commented on Sep 5, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    If your issue is the same, please consider adding a reaction or comment to one of those instead so the team can track it in one place.

  2. thdxr commented on Oct 11, 2026

    @thdxr
    Member

    Thanks for the report! OpenCode 2.0 is now out and development is focused on V2, so we're closing issues filed against OpenCode 1. Please upgrade (opencode upgrade --major, details: https://anoma.ly/notes/opencode-2-0), and if this is still relevant on 2.0, reopen this issue or open a new one with your 2.0 version.

    — from 𝕺𝖕𝖊𝖓𝕮𝖔𝖉𝖊

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions