SIGN IN SIGN UP

fix: don't resurrect locally-closed tabs as dead shell panes (#14)

Closing a mirror tab locally tombstones its pane entries, but a TabEntry
has no tombstone of its own — its stale local id just stops resolving.
The next converge saw tab_exists == false and rebuilt the tab from the
remote layout wholesale: layout.apply created a titled local pane for
every leaf, and only afterwards did the mapping loop consult tombstones
and skip them. The skipped panes were left as untracked plain shells
parked in the .mirror-pane marker cwd, with no streamer ever exec'd in —
and closing them re-triggered the same rebuild on the next converge.

Two changes in the converge pass:
- skip a tab rebuild entirely (before the layout.export round-trip) when
  every remote pane in the tab is tombstoned — the user closed this
  tab's mirror, and the tombstones say don't recreate it. `restore`
  deletes the tombstones, which lifts the skip.
- when a rebuilt tab holds a mix of live and tombstoned panes, prune the
  tombstoned leaves from the exported tree (collapsing single-child
  splits) before layout.apply, so only panes that will actually get a
  streamer are created.
L
Lam Chan committed
5169066ed78910bc4ad3e979b3c8381369e7bc0d
Parent: 1b23976
Committed by GitHub <noreply@github.com> on 7/27/2026, 2:41:52 PM