wezterm
wezterm copied to clipboard
When reattaching to tmux, wezterm prints the current version number
What Operating System(s) are you seeing this problem on?
Windows
Which Wayland compositor or X11 Window manager(s) are you using?
No response
WezTerm version
20231029-184147-bc99181f
Did you try the latest nightly build to see if the issue is better (or worse!) than your current version?
Yes, and I updated the version box above to show the version of the nightly that I tried
Describe the bug
When opening tmux for the first time (new server, or reattaching to a pane the first time), the current version of wezterm is printed into tmux. Mildly irritating when this hits a shell prompt and very irritating when it hits vim.
To Reproduce
My tmux version is tmux 3.2a
. Reattach to an existing tmux pane.
Configuration
I don't think there's anything relevant, but here it is:
-- Pull in the wezterm API
local wezterm = require 'wezterm'
-- This table will hold the configuration.
local config = {}
-- In newer versions of wezterm, use the config_builder which will
-- help provide clearer error messages
if wezterm.config_builder then
config = wezterm.config_builder()
end
-- This is where you actually apply your config choices
-- For example, changing the color scheme:
config.color_scheme = 'Dracula'
if wezterm.target_triple == 'x86_64-pc-windows-msvc' then
config.default_prog = { 'wsl', '--cd', '~' }
end
config.window_close_confirmation = 'NeverPrompt'
-- config.disable_default_key_bindings = true
config.keys = {
-- Turn off the default CMD-m Hide action, allowing CMD-m to
-- be potentially recognized and handled by the tab
{
key = 'V',
mods = 'CTRL',
action = wezterm.action.PasteFrom 'Clipboard'
},
{
key = 'C',
mods = 'CTRL',
action = wezterm.action.CopyTo 'Clipboard'
},
{
key = '0',
mods = 'CTRL|SHIFT',
action = wezterm.action.ActivateTab(0)
},
{
key = '1',
mods = 'CTRL|SHIFT',
action = wezterm.action.ActivateTab(1)
}
}
config.check_for_updates = false
config.hide_tab_bar_if_only_one_tab = true
config.scrollback_lines = 35000
config.font_size = 13
config.font = wezterm.font('CaskaydiaCove Nerd Font', { weight = 'Light' })
return config
Expected Behavior
Wezterm should not print stuff.
Logs
No response
Anything else?
No response
Seeing this exact behavior. Struggling to find a workaround. #2060 did not help.
+1, I did not find this issue before so I opened https://github.com/wez/wezterm/issues/5342 which is probably the same; feel free to close that one
This issue also crops up when using yazi
inside tmux
and it causes keyboard shortcuts to activate. Interestingly, when I am ssh
'd into a different server inside tmux
, I don't get the error:
i.e.
- Enter WSL Ubuntu-24.04
- Launch
tmux
- Launch
yazi
- Problem occurs (several shortcuts activate in sequence)
- Exit
yazi
-
ssh
to server from inside the sametmux
session - Launch
yazi
- No problem
FYI, this is likely due to ConPTY, see https://github.com/sxyazi/yazi/issues/1557#issuecomment-2340294607
The good news is that the new ConPTY implementation has fixed this issue and should be available for WezTerm soon! 🚀
Thanks @sxyazi! I figured that ConPTY had something to do with it. I wonder if the new version will finally allow escape sequences for undercurl and such!