detached f1db0f5

fix(daemon): defer floating activation wiring

commit
f1db0f5a0c7d082809bc7b4ba2e0678c578911ca
author
brice · · 2026-07-10 00:22 UTC
committer
brice · · 2026-07-10 05:40 UTC
parent
0fef5f3
signature
GPG VerifiedCD88F9E564E0102646FB6077A1A07C7C7C3E349D · arch-gpg Verified for the committer email
2 files · +6 -4
M internal/usecase/daemon/client.go +0 -3
@@ -398,9 +398,6 @@ func (d *Daemon) attachClient(sess *session, tr ports.Transport, sz domain.Size,
398398 d.touchMRU(sess)
399399 d.log.Info("client attached", "session", name, "resume", opts.resumeCapable)
400400 d.applyHostTheme(sess, ac, d.effectiveTheme(themeui.Theme{}), true)
401- // A restored inactive tab remains cold; the attached active tab starts its
402- // independent popup prewarm asynchronously.
403- d.ensureFloatingWarm(sess, sess.activeTab())
404401 return ac, old
405402 }
406403
@@ -398,9 +398,6 @@ func (d *Daemon) attachClient(sess *session, tr ports.Transport, sz domain.Size,
398 d.touchMRU(sess)398 d.touchMRU(sess)
399 d.log.Info("client attached", "session", name, "resume", opts.resumeCapable)399 d.log.Info("client attached", "session", name, "resume", opts.resumeCapable)
400 d.applyHostTheme(sess, ac, d.effectiveTheme(themeui.Theme{}), true)400 d.applyHostTheme(sess, ac, d.effectiveTheme(themeui.Theme{}), true)
401- // A restored inactive tab remains cold; the attached active tab starts its
402- // independent popup prewarm asynchronously.
403- d.ensureFloatingWarm(sess, sess.activeTab())
404 return ac, old401 return ac, old
405 }402 }
406 403
M internal/usecase/daemon/snapshot_restore_test.go +6 -1
@@ -112,9 +112,14 @@ func TestRestoreSnapshotsLeavesFloatingUninitializedAndInactiveTabsCold(t *testi
112112 {Cols: 80, Rows: 24, Tree: layout.NewTree("pane-1"), Panes: []snapcodec.Pane{{ID: "pane-1", Cwd: "/two"}}},
113113 },
114114 })}}}
115- d := newTestDaemon(t, &restorePTYFactory{}, stubClock{})
115+ factory := &restorePTYFactory{}
116+ d := newTestDaemon(t, factory, stubClock{})
117+ d.ApplyConfig(domain.Config{Floating: domain.FloatingConfig{Command: "btop", Width: 80, Height: 80}})
116118 WithSnapshotStore(store)(d)
117119 d.restoreSnapshots(context.Background())
120+ // Only the persisted normal panes may be restored. Floating runtimes are
121+ // deliberately excluded and must wait for a Phase-5 activation path.
122+ require.Len(t, factory.opens, 2)
118123 d.mu.Lock()
119124 restored := d.findByNameLocked("work")
120125 d.mu.Unlock()
@@ -112,9 +112,14 @@ func TestRestoreSnapshotsLeavesFloatingUninitializedAndInactiveTabsCold(t *testi
112 {Cols: 80, Rows: 24, Tree: layout.NewTree("pane-1"), Panes: []snapcodec.Pane{{ID: "pane-1", Cwd: "/two"}}},112 {Cols: 80, Rows: 24, Tree: layout.NewTree("pane-1"), Panes: []snapcodec.Pane{{ID: "pane-1", Cwd: "/two"}}},
113 },113 },
114 })}}}114 })}}}
115- d := newTestDaemon(t, &restorePTYFactory{}, stubClock{})115+ factory := &restorePTYFactory{}
116+ d := newTestDaemon(t, factory, stubClock{})
117+ d.ApplyConfig(domain.Config{Floating: domain.FloatingConfig{Command: "btop", Width: 80, Height: 80}})
116 WithSnapshotStore(store)(d)118 WithSnapshotStore(store)(d)
117 d.restoreSnapshots(context.Background())119 d.restoreSnapshots(context.Background())
120+ // Only the persisted normal panes may be restored. Floating runtimes are
121+ // deliberately excluded and must wait for a Phase-5 activation path.
122+ require.Len(t, factory.opens, 2)
118 d.mu.Lock()123 d.mu.Lock()
119 restored := d.findByNameLocked("work")124 restored := d.findByNameLocked("work")
120 d.mu.Unlock()125 d.mu.Unlock()

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 12

Tags 11

↑↓ moveenter openesc close