t3code icon indicating copy to clipboard operation
t3code copied to clipboard

[Bug]: gibberish rgb escape codes appear in terminal

Open nathanscain opened this issue 8 months ago • 5 comments

Before submitting

  • [x] I searched existing issues and did not find a duplicate.
  • [x] I included enough detail to reproduce or investigate the problem.

Area

apps/desktop

Steps to reproduce

  1. use the terminal
  2. some combination of restarts / version changes / upgrades / computer restarts (really unclear)
  3. open terminal to see a bunch of escape codes typed in the terminal

Expected behavior

terminal restores to previous state without escape codes

Actual behavior

common to see escape codes in a restored terminal (the majority of my threads)

t3code-278c6346 on git ci/add-generated-attributes [$] via node 25.8.1 on aws company 
> 10;rgb:f5f5/f5f5/f5f511;rgb:1616/1616/16161;2c10;rgb:f5f5/f5f5/f5f511;rgb:1616/1616/16161;2c10;rgb:f5f5/f5f5/f5f511;rgb:1616/1616/16161;2c

t3code-278c6346 on git ci/add-generated-attributes [$] via node 25.8.1 on aws company 
> ^[]10;rgb:f5f5/f5f5/f5f5^[\^[]11;rgb:1616/1616/1616^[\^[[?1;2c^[]10;rgb:f5f5/f5f5/f5f5^[\^[]11;rgb:1616/1616/16

t3code-278c6346 on git ci/add-generated-attributes [$] via node 25.8.1 on aws company 
> 10;rgb:f5f5/f5f5/f5f511;rgb:1616/1616/16161;2c10;rgb:f5f5/f5f5/f5f511;rgb:1616/1616/16161;2c

Impact

Cosmetic issue

Version or commit

0.0.13

Environment

macos 26.3, installed via homebrew

Logs or stack traces


Screenshots, recordings, or supporting files

No response

Workaround

ctrl+c to get a new line and ignoring it

nathanscain avatar Mar 20 '26 15:03 nathanscain

I was able to reliably reproduce this on my machine by:

  1. Opening a new file in vim/nvim
  2. Closing it (:q)
  3. Minimise terminal with Cmd + J
  4. Reopen terminal with Cmd + J -> Random terminal characters appended to the terminal output each time its reopened.

Typing exit in terminal to close it (instead of Cmd + J) and reopening seems to clear the issue.

T3 Code Version: 0.0.17-nightly.20260415.45

Video reproduction: https://github.com/user-attachments/assets/154e23a0-25aa-41e3-a1c1-286dae5403a4

No idea if this is helpful as I'm not that knowledgeable in this area, but hope it helps.

mmmattG avatar Apr 16 '26 10:04 mmmattG

I'm experiencing same, when I switch projects or restore a terminal, the prompt gets flooded with repeated escape-reply fragments like: 2026;2$y2027;0$y2031;0$y2048;0$y1$r0m. It seems that it happens cause replayed history contains control-query bytes, so restore keeps generating fresh replies.

evkosenk avatar Apr 20 '26 07:04 evkosenk

@maria-rcks, could you please comment on it, does closure means that it was fixed?

evkosenk avatar May 15 '26 07:05 evkosenk

@kedMertens @mmmattG @nathanscain Could you try my branch to check if it fixes the problem

olafura avatar Jun 24 '26 10:06 olafura

@kedMertens @mmmattG @nathanscain Could you try my branch to check if it fixes the problem

Sure thing, will give it a try and report back, thanks

evkosenk avatar Jun 24 '26 11:06 evkosenk