trees: show its phases as N of M, with progress, elapsed time and ETA (closes #113) #121

Merged
clawbot merged 1 commits from issue-113-trees-progress into next 2026-10-16 21:00:15 +02:00
1 Commits
Author SHA1 Message Date
clawbot a2483a84f1 trees: show its phases as N of M, with progress, elapsed time and ETA (closes #113)
check / check (push) Waiting to run
trees now runs in four phases, open, read, group and write, each under
the progress display scan uses, until the summary line. open covers a
wait on a busy database. read counts the records and reads them in one
read-only transaction, so the two agree during a scan; group counts the
directories, and write the groups. The rows reach stdout through a
writer. When stdout and stderr are the same file, it clears the display
and holds its lock while writing, so no row shares a line with the
display on a shared terminal; otherwise it writes without the lock, so
a slow reader of stdout cannot stop the display. Each rate names what
its phase counts.

Judgement call: opening the database is a phase of its own, so there are four phases, not the three the issue sketches.

Model: opus-5-5
2026-10-16 18:36:33 +00:00