opencode icon indicating copy to clipboard operation
opencode copied to clipboard

Input text displays in terminal instead of input box, Enter creates newline instead of submitting (V 1.0.20)

Open nikitalbnv opened this issue 1 year ago • 9 comments

Description

After updating to the newest version, the input handling appears to be broken. Text input is being rendered directly in the terminal display area instead of in the dedicated input box, and pressing Enter creates a newline in the terminal rather than submitting the request.

I ran the old version with bun x [email protected] and everthing there works fine, sometimes terminal escape sequences get dumped on the screen when I'm in the app as well but I can't recreate that problem

I've attached a screenrecording that shows this problem since I'm not too sure how to describe it

https://github.com/user-attachments/assets/474f2462-e78a-4838-9c6c-973648b78f46

OpenCode version

1.0.20

Steps to reproduce

ghostty --version                                                                          ~
Ghostty 1.2.3-arch2

Version
  - version: 1.2.3-arch2
  - channel: tip
Build Config
  - Zig version   : 0.14.1
  - build mode    : builtin.OptimizeMode.ReleaseFast
  - app runtime   : apprt.Runtime.gtk
  - font engine   : font.main.Backend.fontconfig_freetype
  - renderer      : renderer.generic.Renderer(renderer.OpenGL)
  - libxev        : io_uring
  - kernel version: 6.17.7-arch1-1
  - desktop env   : other
  - GTK version   :
    build         : 4.20.2
    runtime       : 4.20.2
  - libadwaita    : enabled
    build         : 1.8.1
    runtime       : 1.8.1
  - libX11        : enabled
  - libwayland    : enabled

Screenshot and/or share link

No response

Operating System

6.17.7-arch1-1

Terminal

Ghostty but same issue on Alacritty and Kitty

nikitalbnv avatar Nov 09 '25 03:11 nikitalbnv

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

  • #4046: Similar input handling issues in v1.0 with Ghostty terminal where keybindings don't work as expected
  • #1505: Enter key behavior problems and input handling issues in the TUI
  • #3927: Input handling regression in v1.0.24 where multi-line input is fragmented
  • #3699: TUI input problems in v1.0.7 specifically with Ghostty terminal
  • #344: Enter and newline key issues with Ghostty terminal in earlier versions

Feel free to ignore if none of these address your specific case.

github-actions[bot] avatar Nov 09 '25 03:11 github-actions[bot]

If you scroll or do something else, TUI is not interpreting

Beloin avatar Nov 09 '25 03:11 Beloin

Can yall try the latest version? We addressed a lot of issues recently?

@Beloin what version r u on?

rekram1-node avatar Nov 09 '25 05:11 rekram1-node

@rekram1-node its something weird. Sometimes it works, but sometimes it just bugs and dont undestand inputs.

I am using with neovim, but TUI client also shows the same problems.

In neovim Image

in opencode TUI Image

Version:

Image

Beloin avatar Nov 09 '25 05:11 Beloin

@Beloin can you upgrade to latest tho? Like I said I think we fixed some of these issues already

rekram1-node avatar Nov 09 '25 05:11 rekram1-node

Sorry, I thought it was already the latest version. I will try tomorrow ( already 2Am at my local time ) and notify this thread. Also I will try to use the compiled binary, or build it. AUR package is weird sometimes

Beloin avatar Nov 09 '25 05:11 Beloin

It's fixed for me on the new version

I had it installed via yay from the aur package & it was telling me that 1.0.20 was the latest version, sorry about that

nikitalbnv avatar Nov 09 '25 06:11 nikitalbnv

no problem :)

rekram1-node avatar Nov 09 '25 14:11 rekram1-node

It fixed also for me. Sorry for the confusion

Beloin avatar Nov 09 '25 22:11 Beloin