Skip to content

[BUG] Web UI crashes when pasting large log text into the input box #40229

Closed as not planned

Description

@GuoChen-thlg

Problem Description

In the opencode Web UI, when pasting a large amount of log text into the chat input box, the page crashes. After refreshing the page, the page displays normally again, and the pasted log content can be successfully sent.

Steps to Reproduce

  1. Open the opencode Web UI
  2. Create a new session
  3. Paste a large amount of log text into the chat input box
  4. Observe the page crash

Expected Behavior

Pasting large text into the input box should not crash the page; the content should remain editable and sendable.

Actual Behavior

The page crashes immediately after pasting large log text. However, after refreshing, the page renders normally and the log content can be sent successfully.

Environment

  • opencode version: v1.18.6
  • Mode: Web UI

Activity

  1. github-actions commented on Aug 3, 2026

    @github-actions
    Contributor

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

  2. NuWhE3wn0D commented on Aug 3, 2026

    @NuWhE3wn0D

    It seems like the page crashes when the input box is overwhelmed with a large amount of data. A potential cause could be the lack of efficient handling for large strings in the handleInputChange function within the input box component. Have you checked if there are any performance bottlenecks or memory issues during the paste operation, perhaps using browser dev tools to monitor performance metrics? Also, implementing a limit on the character count before the paste occurs could help mitigate this behavior temporarily.

  3. GuoChen-thlg commented on Aug 3, 2026

    @GuoChen-thlg
    Author

    当输入框输入大量数据时,页面似乎会崩溃。一个可能的原因是输入框组件中的 handleInputChange 函数对长字符串的处理效率不高。您是否检查过粘贴操作期间是否存在性能瓶颈或内存问题?例如,可以使用浏览器开发者工具监控性能指标。此外,在粘贴操作之前限制字符数或许可以暂时缓解此问题。

    Image I have pasted a 25,3888-character log entry. After refreshing, the pasted content still exists. This indicates that the input box processing performance is poor. However, the content can still be sent normally.

  4. github-actions commented on Oct 3, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

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