Tab bar briefly shows an outdated tab list on first revisit after creating a tab
Tab bar briefly shows an outdated tab list on first revisit after creating a tab
Description
After creating a tab, the tab bar can briefly show an older tab list when switching away or back. The new tab's label disappears and then returns; the tab and its contents remain intact.
Waiting 5–10 seconds after creation does not prevent it. With several existing tabs, each can flash on its first visit after the tab list changes. Once every tab has been visited, switching settles down until another tab is created or replaced.
This seems to have started with an upgrade after 0.43.x, but I have not bisected the regression. I normally use zjstatus; an isolated test also captured the stale label with the built-in zellij:tab-bar on 0.45.0.
Steps to reproduce in the affected configuration
- Start a session with a tab-local bar in
default_tab_template. - Create a tab with
Alt+n; it receives focus immediately. - Wait 10 seconds.
- Switch to the previous tab with
Alt+i, then back withAlt+o. - Watch the tab labels on the first revisit: the new label can briefly disappear before returning.
Relevant keybindings:
bind "Alt n" { NewTab; SwitchToMode "normal"; }
bind "Alt i" { GoToPreviousTab; }
bind "Alt o" { GoToNextTab; }Layout used for the built-in-bar comparison:
layout {
default_tab_template {
children
pane size=1 borderless=true {
plugin location="zellij:tab-bar" {
hide_swap_layout_indication "true"
}
}
}
}The affected configuration has pane_frames false, simplified_ui true, and session_serialization false, and loads strider, session-manager, and link in the background.
Reproduction limitation: the built-in comparison retained the existing configuration. Two subsequent tests with stripped-down configuration and the built-in bar on 0.45.1 did not capture the flash. The layout above is therefore not yet a reliable standalone reproducer; configuration and timing may matter.
Expected behavior
Switching tabs should display the current tab list immediately, without briefly showing a list from before the new tab existed.
Evidence
An automated PTY capture using /bin/sh recorded this sequence with the built-in bar on 0.45.0, after waiting 10 seconds on the new tab:
Before switching: Zellij Tab #1 Tab #2 +
16.106 s: Zellij Tab #1 +
16.123 s: Zellij Tab #1 Tab #2 +The 17 ms interval is between PTY observations, not a screen-recorded display duration. The same capture method observed the disappearing label with zjstatus 0.25.0 on both Zellij 0.45.0 and 0.45.1, with the existing configuration.
Environment
- Linux x86_64, kernel
6.17.0-1032-oem. - Interactive terminal: WezTerm
20240203-110809-5046fc22. - Isolated captures: 140×32 PTY,
/bin/sh,TERM=xterm-256color. - Zellij: 0.45.0 installed; official 0.45.1 Linux musl binary tested separately.
- zjstatus: official 0.25.0 artifact, checksum verified; automatic frame hiding disabled.
Possible lead
#4918 restricts tab updates to active-tab and background plugins. The observed sequence is consistent with a previously inactive bar being displayed before its fresh TabUpdate is rendered. This is a hypothesis, not a bisected cause.
This differs from the plugin-loading flash in #4466: it occurs after the new tab has settled, when revisiting an existing tab. It also concerns tab-list contents rather than the stale input-mode display addressed by #5535.
Source: zellij-org/zellij