Skip to content

Show hidden quiet-history runs in the Log on request - #173

Merged
danielmaier42 merged 7 commits into
mainfrom
feature/log-show-quiet-runs
Nov 11, 2026
Merged

danielmaier42 merged 7 commits into
mainfrom
feature/log-show-quiet-runs

Conversation

@danielmaier42

Copy link
Copy Markdown
Owner

What changes

  • A quiet-history task's successful run is now recorded as a hidden run ("quiet": true in history.jsonl), with its log. Before, it left no trace.
  • Hidden runs are kept for 48 hours, at most the newest 200 per task, and are deleted with their logs after that. They do not count against Keep run history, so a watcher that ticks every few minutes never pushes real runs out. Expired ones are pruned after every run and when the daemon starts.
  • Log view: the Filter popover gets a Show hidden runs switch. It is temporary: it lives in memory only, so a reload or restart turns it off again. While it is on, a "Hidden runs shown" chip sits in the toolbar and every hidden run is greyed and marked with an eye icon and "Hidden" (just the icon in narrow rows).
  • A failed hidden run always shows, with or without the filter. Failures, auth errors, cancellations and rate-limit pauses of quiet tasks are recorded as ordinary runs, as before; tests now pin this.
  • Hidden runs are never unread and never notify (unchanged). They stay out of the Usage statistics and of what Ask DispatchQ lists, which can still find one by its run id.
  • API: GET /api/runs leaves hidden runs out by default, and ?hidden=1 includes them. GET /api/runs/{id} finds them, so a notification link to a quiet run's result now opens its log.
  • CLI: dispatchq status (including --all --json, which scripts read) leaves hidden runs out unless you pass --hidden. With it, the JSON carries "quiet": true. run-now on a quiet task now prints the result instead of "no run recorded".
  • README updated: feature list, Log view, settings table, CLI reference, the quiet history section, and Data on disk.

External readers of history.jsonl

I checked claudeq-failure-watch/watch.py read-only. It reports nothing new for a success row: failures() only looks at failed, and attention_reason() returns nothing for success. A hidden success does count as "a later run of the same task". A quiet task's rate-limit pause that was later resumed and succeeded no longer raises a false "resume overdue" alert, and its earlier non-defect failure is no longer reported once a later tick succeeds. That is the same rule ordinary tasks already follow. A hidden run's log is deleted together with its history row, so the orphaned-log check is not tripped.

Downgrade

update.DataFloor stays the same: older releases can still read the file and simply ignore quiet. After a downgrade, the hidden runs still on disk would show as ordinary runs until they age out under the normal cap.

Verification

  • go build, gofmt, go vet, golangci-lint (0 issues), go test ./... -race, plus web typecheck, lint, vitest (283 tests) and build all pass.
  • I ran each new regression test against a checkout without its fix to make sure it fails, then with the fix to make sure it passes. Covered: engine recording, retention/cap, API listing, history cap, and CLI status.
  • End to end: a daemon on a temporary DISPATCHQ_HOME running real script tasks, with the dev UI captured by headless Chromium at desktop and narrow width.

🤖 Generated with Claude Code

Daniel Maier and others added 7 commits November 11, 2026 18:13
A quiet-history task's successful run is now recorded, marked "quiet": true,
with its log. Hidden runs are kept for 48 hours (at most 200 per task), do not
count against the run history limit, are never unread, and stay out of the
default Log, `dispatchq status` and the usage statistics. The Log's Filter
popover gains a temporary "Show hidden runs" switch (memory only) that lists
them, each marked Hidden. Failed runs of quiet tasks keep showing without it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Optimistic run patches (read, cancel) and a run-now's new run now reach the
Log's list while Show hidden runs is on. Mark all read skips quiet runs, so
state.json does not collect every watcher tick. The UI says hidden runs are
kept for up to 48 hours, since the per-task cap can end that sooner. Runs and
PruneHistory read history through the same helper as PruneQuietRuns.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t-runs

# Conflicts:
#	README.md
#	internal/store/store.go
…the Log filter reachable

AppendRun, PruneHistory and PruneQuietRuns now hold the store's cross-process
write lock, so a rewrite by one process (the daemon, or `dispatchq run-now`)
no longer drops a run the other appended meanwhile. Hidden runs are pruned
once more than 20 are due, instead of rewriting history on every watcher tick.

The Log keeps its toolbar whenever the list is loaded or Show hidden runs is
on: an install whose only runs are hidden can reach the switch, and an empty
list with the switch on still shows the chip that turns it off. The empty
state says where hidden runs are.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…write

Review follow-up. Hidden runs are pruned once more than 20 are due or once one
is six hours past its 48 hours, so a stopped or rarely ticking watcher still
loses them on schedule. PruneHistory and PruneQuietRuns read history without
the cross-process lock and take it (reading again) only for a rewrite, so a
finished run with nothing to drop holds nobody up. The Log's empty state
mentions hidden runs only when the queue has a quiet-history task.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review follow-up. The daemon drops all expired hidden runs when it starts,
batch or not, so a queue whose only quiet task stopped does not keep them.
PruneHistory and PruneQuietRuns share one helper for the decide-then-lock
rewrite; a read error in the unlocked pass (another process's append caught
mid-line) is left to the pass under the lock. The cross-process test no longer
reports from a goroutine after the test ended.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@danielmaier42
danielmaier42 merged commit ddb052b into main Nov 11, 2026
4 checks passed
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

Successfully merging this pull request may close these issues.

1 participant