Skip to content

The terminal UI display is abnormal #1146

Closed

Description

@srcrs

I'm using a MacBook, using the iterm terminal, and installed oh my zsh, but there are some issues with the display. In version v0.3.24.

brew install sst/tap/opencode
Image

Activity

  1. thdxr commented on Jul 19, 2025

    @thdxr
    Member

    can you do opencode upgrade 0.3.24 to downgrade and see if it's better?

  2. calebrjc commented on Jul 19, 2025

    @calebrjc

    Unsure if this would be the same issue, but I see similar behavior, specifically after sending a message. The commands and help that I used did not break the UI, but sending the first message did.

    The "broken" screenshot is in v0.3.22 and the "normal" one is in v0.3.21, though I first experienced the behavior with v0.3.28, as I just installed this tool on my machine today.

    I'm on Linux (Fedora 42), currently using Konsole as my terminal, and running zsh and oh-my-zsh. Installed via curl + bash.

    Image Image
  3. magnusoverli commented on Jul 20, 2025

    @magnusoverli

    I am also seeing this issue. Not sure exactly in what version it started, but there was some change to how diffs were displayed (side-by-side) around 0.3.20? I think that is when it started, and it has become worse lately. Almost to a point where I am unable to use opencode...
    I am running CachyOS with the default KDE desktop.

    Image
  4. magnusoverli commented on Jul 20, 2025

    @magnusoverli

    It was introduced in 0.3.22 I think. This feature is mentioned: feat(tui): simpler layout, always stretched.

    I do not see this issue before this release.

  5. adamdotdevin commented on Jul 21, 2025

    @adamdotdevin
    Member

    haven't been able to reproduce this yet, any more detail or ideas welcomed! i hate visual bugs and i want to kill this one asap 😅

  6. magnusoverli commented on Jul 21, 2025

    @magnusoverli

    Not sure how I can contribute more insight. Could it be shell related? I guess the firs poster is using ZSH? Personally I am using fish on cachysOS. Do they have anything in common that may contribute to the issue? Any non-standard color/formatting/non-posix-stuff?

  7. magnusoverli commented on Jul 21, 2025

    @magnusoverli

    Sort of meta, but here goes... https://opencode.ai/s/NNvk7S6b

  8. adamdotdevin commented on Jul 21, 2025

    @adamdotdevin
    Member

    interesting. does the layout correct itself if you resize your terminal window/pane?

  9. magnusoverli commented on Jul 21, 2025

    @magnusoverli

    It does sometimes. It seems to "like" certain widths better than others.

  10. lazycoder9 commented on Jul 22, 2025

    @lazycoder9

    Hey, hope this video helps. I'm on iTerm2 with zsh, MacOS Sonoma 14.5 and you can see how layout behaves in different situations

    opencode_tui_bug.mp4
  11. ilkerhk commented on Jul 22, 2025

    @ilkerhk

    I'm having the same issue and unfortunately it is making opencode unusable for me.
    Not a workaround but xterm (instead of konsole or yakuake) seems to work fine

    EDIT: This issue might not be a bug. In my case (using konsole/yakuake in KDE) the TERM env variable was wrongly set to xterm-256color. Changing it seems to fix the issue:

    export TERM=konsole-256color

  12. adamdotdevin commented on Jul 23, 2025

    @adamdotdevin
    Member

    will take a look at this again tomorrow morning, more clues have come in, hoping to reproduce and track this down

  13. adamdotdevin commented on Jul 23, 2025

    @adamdotdevin
    Member

    could you all tell me what your TERM env variable is set to? (echo $TERM)

  14. 26 remaining items

  15. lucasff commented on Oct 17, 2025

    @lucasff

    I also have the same issue, with MacOS and iTerm2, using Zsh and Powerlevel10k

  16. vasyan commented on Oct 21, 2025

    @vasyan

    Have similar issue with iTerm2. I toggling between zoom+ zoom- hotkeys till it fix the visual artifacts, but it is a pain in neck.
    However, terminal in Cursor do the trick.

  17. ecker00 commented on Oct 23, 2025

    @ecker00

    I still have issues with this, and adding export TERM=konsole-256color to my ~/.zshrc / ~/.bashrc solved it for me.

  18. wThomas84 commented on Oct 24, 2025

    @wThomas84

    For me the workaround is to run opencode within a tmux session. That also has the advantage, that I can switch between different instances of different projects by using tumx' window feature.

    Running on KDE Konsole 23.08.5, using zsh.

  19. ktalanov commented on Oct 29, 2025

    @ktalanov

    I'm sure you're working on this, but to point out this issue very much still exists. I would have given up on the project if I didn't manage to ask it to figure out this issue for me. It didn't, but it did point me to this bug submission. FWIW, Fedora 43 coems with $TERM set to xterm-256color by default. Interestingly enough, when I installed an actual instance of xterm it did not exhibit the problematic behaviour. (For me), it's fixed by setting TERM to konsole-256color. The video speaks for itself (and my sense of humour, apparently.)

    me@fedora:~$ opencode --version
    0.15.23
    
    me@fedora:~$ bash --version
    GNU bash, version 5.3.0(1)-release (x86_64-redhat-linux-gnu)
    

    Edit: just saw the update, didn't check what it was for but the same behaviour in 0.15.26.

    and

    me@fedora:~$ konsole --version
    konsole 25.08.2
    

    Here's the unnecessarily-long video with hopefully some info you didn't have before, though I somehow doubt it will shine much new light:

    Screencast_20251029_131710.mp4
  20. rekram1-node commented on Oct 29, 2025

    @rekram1-node
    Contributor

    Thanks @ktalanov

  21. bitzerk commented on Oct 30, 2025

    @bitzerk

    EDIT: The issue no longer persists for me in v1.0.0 🙌


    I also have this visual glitch. I use yakuake with zsh.

    When I edit my yakuake profile, and go to General > Environment > Edit, I see the following environment vars are set:

    Original ENV Vars Set:

    TERM=xterm-256color
    COLORTERM=truecolor

    Result:

    Image

    If I comment out the second line, my colors don't match the theme I select in opencode, BUT the glitch disappears 🤔:

    Commented-out COLORTERM env var:

    TERM=xterm-256color
    #COLORTERM=truecolor

    Result:

    Image

    I don't know the solution here, just thought it could help get everyone one-step closer.


    EDIT:

    I've noticed that some themes are still broken, even with this change - but most aren't. I'm using evergreen theme in my example that is working.

  22. strk commented on Dec 28, 2025

    @strk

    This is still a problem with 1.0.62 - I confirm that under tmux (as suggested by @wThomas84) the terminal becomes readable (luck?)

  23. rozgo commented on Jan 3, 2026

    @rozgo
    Image Image

    This is vanilla osx terminal. Its still unusable.

  24. IanKeefer commented on Jan 6, 2026

    @IanKeefer

    Image Image
    This is vanilla osx terminal. Its still unusable.

    Getting the exact same result as these screenshots. Attempted every individual theme too an all are scuffed.

    15.6.1 in osx terminal

  25. echoborealis commented on Jan 28, 2026

    @echoborealis

    Image Image
    This is vanilla osx terminal. Its still unusable.

    +1 on this, same behaviour on default macOS 15.x terminal, 26.x works fine.
    Disabling ANSI colors helps with text readability, but it removes, well, colours.
    I think that there's some issue with colouring and opencode just defaults to ANSI if something is not working properly

    Terminal version with issues is 2.14 (455.1)

  26. haliliceylan commented on Feb 9, 2026

    @haliliceylan

    I have same problem, with osx terminal

  27. R44VC0RP commented on Feb 9, 2026

    @R44VC0RP
    Contributor

    hi everyone, please make sure you are updated to the latest version when providing repos please

  28. kommander commented on Apr 1, 2026

    @kommander
    Contributor

    Use a true-color terminal like Ghostty or Kitty. Indexed color fallback for old/bad terminals is on the roadmap.

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