| Age | Commit message (Collapse) | Author |
|
a pane in several sessions (a session group, `new-session -t`, or a
linked window) was listed once per session: every agent of a group showed
twice in the menu, panel, search, `dingger status`, and the counts. and
snapshots saved each session of a group with its own copy of the windows,
so restore would have rebuilt them twice and resumed each agent twice on
one session file.
- a pane keeps its first listing (tmux lists sessions by name) and is
attended if the user looks at it through any session of the group.
- snapshots keep the first session of each group; the others are not
restored.
e2e step 19 covers both; the previous binaries fail it. two checks (step
11's and this one) waited for idle after a turn that started from idle,
which passed before the turn was even processed: they now wait for
working first, and the negative control for group attendance fails as it
should. step 18 now waits for the snapshot it later restores from.
|
|
`dingger install claude` adds a SessionStart hook to Claude's settings
(every other key and hook kept, in order; the original backed up; written
through a symlink; installing again changes nothing). The hook is
`dingger hook claude`: it reports the session's transcript for its tmux
pane, prints nothing (Claude adds SessionStart output to the conversation)
and always exits 0. Claude's state still comes from its screen.
restore types `claude --resume <id>` in the directory the session ran in
(elsewhere, Claude moves the conversation there). it resumes an agent only
when its session file exists: a Claude session that never got a message
has no transcript, and `--resume` fails ("No conversation found"). the
snapshot now keeps an agent's command line too, so such a pane gets it
retyped instead of nothing.
- the hook receiver takes a report without a state: only the session.
- a report that arrives after the watcher listed the panes is not dropped
as "agent gone": Claude reports once, as it starts.
- serde_json preserve_order (indexmap is already a dependency, via toml).
e2e step 18: install against a settings file like a real one, a fake
claude running the exact installed hook command, resume by id, retype
without a transcript, the resumed agent reporting again. a server that
restore starts now gets the test's plain shells: it got the user's login
shell, whose profile put the real claude first, which started (stuck at
its trust dialog) during development. every test restore now checks that
no real pi or claude runs in a test pane.
|
|
- the pi extension reports its session file; the daemon keeps it in the
pane option @agent_session, and snapshots carry it. restore runs
`pi --session <file>` in the rebuilt pane, one agent every 0.5s, then
reports which agents run and which were interrupted mid-turn.
- other panes: the command line running in them is typed at the new
prompt but not run. exactly as typed with the zsh hook (dingger install
zsh: preexec/precmd keep @dingger_cmd), else the foreground program's
exact argv from the kernel (KERN_PROCARGS2), shell-quoted.
- "at a prompt" is the pane's own shell owning the terminal's foreground
process group, not a name check: `sh -c ...` is a running program.
- an agent or command that exits keeps its place in snapshots for 60s, so
a shutdown that stops programs before tmux still restores them.
- typing waits for each new prompt (text typed earlier echoes twice).
e2e step 16 covers resume with a session path containing a space, the
interrupted report, an agent that exits just before the server dies, a
quoted command retyped not run, and the hook's text; dropping the grace
period, judging prompts by name, running retyped commands, or not storing
the session reference each fail it. the test's fake pi is guarded so a
real pi never starts.
|
|
the daemon saves the tmux layout when it changes: sessions, windows
(index, name, automatic-rename, layout, size, zoom, active), and panes
(directory, active, agent). a new history file for layout changes, a
rewrite for details, the last 50 kept, nothing saved while tmux is down.
when a different server runs (or none), the old server's last snapshot is
pinned as the restore candidate before the new server's snapshots start.
dingger restore rebuilds missing sessions by tmux id: panes split from the
newest so they keep their order, the saved layout applied at the saved
size, then the size released so windows follow clients again. a bare
session of the same name (a terminal's `new-session -As 0`) is replaced,
its clients switched over first; used sessions are kept. --dry-run,
--list, --from, --session.
e2e step 16 kills a server with a client attached like ghostty's, restarts
it, restores, and compares every window and pane; splitting the wrong
pane, not replacing bare sessions, not pinning, or keeping the saved size
each fail it. e2e keeps its state in its temp dir.
|