Unknown OSC escape code: 666;vte.shell.postexec=0 when starting from a terminal #8375
Replies: 3 comments 2 replies
-
It will be something in your shell rc files. Bisect them to find out
what. From looking at the error message it is likely something that is
trying to setup shell integration with some VTE based terminal.
|
Beta Was this translation helpful? Give feedback.
-
I hadn't thought of that but yeah... /etc/profile.d/vte.sh provided by the vte-profile package which is required by gnome-terminal, libvirt, qemu, remmina, toolbox, xfce4-terminal plus others. It's not easily removed. According to the GNOME/vte repo, 666 is
I suppose I can modify the script to remove the offending bits or build kitty locally with a modified vt-parser.c but has anyone looked at actually supporting the VTE_TERMPROP codes? |
Beta Was this translation helpful? Give feedback.
-
There already exist escape codes that predate OSC 666 for all the actually useful parts of
termprops other than possibly the container stuff. OSC 666 just looks
like a grab bag of unrelated things implemented by VTE because they weren't aware
of the existing solutions. So not something I want to implement in
kitty.
Not to mention that vte.sh is VTE shell integration. Which runs only if
the env var VTE_VERSION is set. Which wont be set unless you run kitty
from inside a VTE terminal, so either dont do that, or live with the
error messages when you do.
I have to say installing shell integration for a terminal system
wide so it is always sourced regardless of what context the shell is
running in, is *very poor* design. VTE should really stop doing that.
For example, kitty's shell integration is not installed system wide (at
least by the kitty official binaries, no clue what distro packages do) and
is sourced only when running shells within kitty, thereby making it
robust against this sort of breakage.
And finally, vte.sh has the following:
```sh
# TERM not supported?
case "$TERM" in
xterm*|vte*|gnome*) :;;
*) return 0 ;;
esac
```
This is naive. They are failing to exclude many modern
terminals such as xterm-kitty, xterm-ghostty at a minimum. Not to metion
that xterm itself doesnt support OSC 666. This should
be a whitelist, not a blacklist. Really, they should be using a
dedicated env var for shell integration which they should *unset* in
their shell integration script. See KITTY_SHELL_INTEGRATION.
|
Beta Was this translation helpful? Give feedback.
-
Fedora 41 XFCE w/ zsh and kitty 0.39.1
I haven't seen any other issues or discussions about this but for me, starting kitty from an existing terminal results in the following every time the shell prompt is printed (or maybe the window title is updated?)...
With bash, it's even worse, those messages print twice.
It doesn't seem to be related to the value of PS1 or shell_integration. Even with
export PS1=$
andshell_integration disabled
I still see the errors.Oddly though, if I start kitty from a panel icon and redirect stdout and stderr to a file, I don't see those messages in the file.
Can anyone give me some guidance on this?
Beta Was this translation helpful? Give feedback.
All reactions