zellij-org / zellij

A terminal workspace with batteries included
https://zellij.dev
MIT License
19.42k stars 611 forks source link

tabs / panes lost their working directories on session restore after a reboot #3374

Open n8henrie opened 1 month ago

n8henrie commented 1 month ago

Issue description

I am new to zellij. I have about 15 named tabs in a named session (main). Each tab has a working directory for a project (from which the tab name is derived). I have been able to disconnect and reconnect to this session and am glad to see this works well!

I just had to reboot my machine, and upon resurrecting this session, I found that about half of the tabs had retained their name, but their working directory had been changed to a different directory (~/git/espanso in this case, I doubt the specific directory is relevant except that it was not $HOME or / or something empty). Oddly, the other half of the tabs had retained their working directory.

Minimal reproduction

Somewhat difficult since it requires a full machine reboot, and I just got done changing all of the tabs back to the proper directory. I will report back if this recurs though.

Other relevant information

$ zellij --version
zellij 0.40.1
$ sw_vers
ProductName:            macOS
ProductVersion:         14.5
BuildVersion:           23F79

Is there a user-facing way for me to inspect the cached files -- I assume in ~/Library/Caches/org.Zellij-Contributors.Zellij -- to see if there is something that seems off? All I see is a bunch of UUIDs, so I'm not entirely sure where to look.

Dialga commented 1 month ago

Following this, my cwd in open tabs also aren't being restored.

n8henrie commented 1 month ago

Just rebooted for the first time since posting, this happened again. I made sure to detach from the session before rebooting to see if that would change anything, but it didn't.

I have 14 tabs open, each with a different working directory. Of the 14, 13 of them restored their cwd to ~/git/espanso. 1 of them (the 12th) properly restored its cwd to ~/git/esp32-rust-mqtt -- I don't see any rhyme or reason why that 12th tab worked as expected.

EDIT: Actually, one of the tabs actually had 3 panes; one of the panes incorrectly restored to ~/git/espanso, while the other two stayed in their expected cwd.