Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Session manager focuses tab that last ran it #3834

Open
kbonnici opened this issue Dec 4, 2024 · 1 comment
Open

Session manager focuses tab that last ran it #3834

kbonnici opened this issue Dec 4, 2024 · 1 comment

Comments

@kbonnici
Copy link

kbonnici commented Dec 4, 2024

2. Issues with the Zellij UI / behavior / crash

Issue description

When opening the session manager more than once, zellij will focus whatever tab that last ran it.
this occurs even when switching sessions.

Minimal reproduction

  • create a new session or open an existing one.
  • have at least 2 tabs in the layout. i will refer to them as tab A and tab B.
  • navigate to tab A
  • open session manager
  • do anything with it. switch sessions, or back out of it with Esc.
  • navigate to tab B.
  • open session manager again

it is at this point that zellij will unexpectedly navigate to tab A, since that was the last tab that the session manager was attached to. not only that, but the session manager will also not be opened at this point either, and required the user to hit the keybind to open it again.

Other relevant information

after consulting with others in the discord, we determined the root cause is that the Esc key hides the session manager instead of closing it altogether. opening the session manager and then hitting the close pane keybind actually closes the manager, so this issue doesnt occur again (until you use Esc to back out of the session manager again, of course)

we believe the fix would be to just close the session manager instead of hiding it.

relevant code: https://github.com/zellij-org/zellij/blob/main/default-plugins/session-manager/src/main.rs#L394

Edit: this behaviour has been confirmed to occur on zellij version 0.41.2 and with a default config.kdl

@imsnif
Copy link
Member

imsnif commented Dec 6, 2024

Thanks for the detailed report! I issued a fix for this in: #3841

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants