Your board hit nine hundred cards, and now it slows the whole machine down


Boards are genuinely useful: tasks in columns, who is running, who is waiting, who is stuck — one glance. So you keep using yours. Three months later it has nine hundred cards, most of them finished long ago. And now the laptop fans spin up, switching tabs in the desktop app stutters, and the disk light blinks nonstop while nothing is actually running.

Issue #160281, filed on November 26, measured it: Windows 11, the packaged v0.23.1 desktop app, gateway run serving 10 profiles, a default state.db of 2.36 GB with 9,600 sessions (9,200 of them from cron), two boards carrying 512 and 405 non-archived cards with 32k and 85k events. While idle, the gateway held a median 67% of one core, read 112 MB/s at 27,000 read operations per second — 22 TB over four and a half days.

The report lists seven causes, and the board is only one of them. But it is the easiest to understand, and the one you can act on today.

What one /board call actually reads

Start with what “diagnostics” on a card means. Beside the title and status there is a row of small markers: how many runs this card had, why the last one failed, where it is in review. Those are not fields stored on the card — they are computed from the event table.

The problem is the scope of that computation. A board refresh calls _compute_task_diagnostics(conn, task_ids=None), and task_ids=None means every card. Every refresh recomputes diagnostics for every non-archived card, including the hundreds that finished months ago, even if all you did was scroll. I checked that path in plugins/kanban/dashboard/plugin_api.py; it really is the full set.

Then consider the refresh rate. The desktop client invalidates and refetches the board whenever a task_events frame arrives — and those frames include heartbeats, the periodic “still alive” pings from workers. The status-bar card count keeps a board query alive in every view as well.

So the chain is plain: more cards makes each query heavier; more events (heartbeats included) makes it more frequent. Multiply the two and you get continuous CPU and disk use on an idle machine.

The numbers in the report

Everything below is the reporter’s measurement, not ours — labelled so you can judge how comparable your setup is.

Metric Value
Idle CPU (median) 67% of one core
Disk read (median) 112 MB/s, ~27k read ops/s
Total read over 4.3 days 22 TB
One /board call 27.5 MB to 49.9 MB read, 0.3–0.6 CPU-seconds
After archiving 644 done cards median CPU 48%, reads 58 MB/s

That last row is the point: archiving finished cards took 19 percentage points off median CPU. It does not mean the board is the whole story — the mean stayed near 110 MB/s, which the report attributes to another cause, a status endpoint that rebuilds a lineage index on every poll — but it does prove one thing. Finished cards are not free. While they sit in “non-archived”, every refresh recomputes them.

A single /board call reading tens of megabytes sounds extreme until you picture the database: two thousand cards, each with events and run records, scattered rows that SQLite has to touch page by page.

Four things you can do today

None of this needs a new version. These are existing commands.

One: archive the cards that are done. This is the only lever the report measured as effective:

# How many are done?
hermes kanban list --status done --json | python3 -c "import json,sys; print(len(json.load(sys.stdin)))"

# Archive them by id, taken from that output
hermes kanban archive <id>

# Clean the scratch workspaces they left behind
hermes kanban gc

With hundreds of cards, a small loop beats clicking. Archiving hides a card from the default list, it does not delete it: hermes kanban list --archived still shows it.

Two: one board per project. A board per project takes a single query from nine hundred cards to one or two hundred:

hermes kanban boards create my-project --name "My Project"
hermes kanban --board my-project list

Splitting is not free — cross-project dependencies no longer show in one view. Archive first, split only if it is still slow.

Three: don’t leave the board open all day. This one is inference, not measurement: the report notes the status-bar count keeps a board query alive in every view, so closing the desktop board view should stop that particular query. Use the CLI or chat, open the board when you need to look.

Four: remember that heartbeats count as refreshes. As long as workers are running, event frames keep arriving, so the board refetches most often exactly when the machine is busiest. That is also why the desktop app feels worst during heavy work.

Six more causes in the same report

If you want to use this report to audit your own machine, know that the board is item four of seven:

  1. Session signature hashing: every time the database’s mtime moves (every 0.5 s on a busy install), the signature columns of every session row are re-selected and hashed.
  2. Gated cron ticks still create sessions: a tick the pre-run gate skips still inserts an empty source=cron session row — about 370 a day against 160 real runs — so “sessions changed” never rests.
  3. Skills signature walks every tree every 2 s, across every served profile. We covered that one in the many-profiles idle-CPU post.
  4. Board diagnostics recomputed in full (this article).
  5. Sidebar fan-out: every session change rebuilds the lineage index for each profile database.
  6. No knobs: the report asks for desktop.watch.sessions_interval_s and friends; they do not exist yet.
  7. /api/status rebuilds the lineage index on every poll by opening a fresh SessionDB, producing one-minute spikes of 260–300 MB/s.

All of those fixes are proposals. The issue is open.

Status, and how to tell whether you have it

Nothing here is fixed yet, so upgrading will not make it faster by itself. To check whether your machine matches, measure three things: the gateway process’s CPU, read_bytes from /proc/<pid>/io (or GetProcessIoCounters on Windows), and a py-spy sample to see where the time goes.

# Read throughput: watch read_bytes grow
cat /proc/$(pgrep -f "hermes gateway" | head -1)/io

# Hot stacks (needs py-spy)
py-spy top --pid $(pgrep -f "hermes gateway" | head -1)

If the hot stacks sit in SQLite reads, _compute_task_diagnostics or list_sessions_rich, you have this class of problem. If they sit in filesystem calls (scandir, stat, realpath), the skills-walk cause is more likely.

For how boards are meant to be used — task flow, review handoffs — see the kanban review lifecycle and the dispatch guard. If you run multi-agent work on boards, the v0.23.4 release page covers the recent changes there too.

The takeaway

“Busy while idle” is almost never one cause. The board is worth its own article because it has an immediately usable answer: archive what you have finished. That is housekeeping and performance tuning in the same action — your history should not be re-billed on every refresh.