Skip to content

0.21.2: a run killed by a redeploy no longer parks its source for a whole cadence - #90

Merged
ralyodio merged 2 commits into
mainfrom
stale-run-requeue
Sep 13, 2026
Merged

0.21.2: a run killed by a redeploy no longer parks its source for a whole cadence#90
ralyodio merged 2 commits into
mainfrom
stale-run-requeue

Conversation

@ralyodio

Copy link
Copy Markdown
Contributor

Found while watching the first bulk list on nichedb.dev: today's redeploys can kill a run mid-walk, and startRun had already pushed next_run_at a full cadence out. The tick's reapStaleRuns marked such a run abandoned but left the source parked, which for a monthly bulk list of ten thousand pages meant a month with nothing to show.

  • reapStaleRuns now returns the reaped runs' sources and sets their next_run_at = now() (paused sources excepted), so the walk resumes from its cursor at the next tick.
  • Two tests in test/rollout-recovery.test.js run the same statements against the in-process Postgres: an abandoned run is marked and its source is due again; a run inside its window and a paused source are left alone.

Version 0.21.2.

🤖 Generated with Claude Code

https://claude.ai/code/session_01MwAoNvWzezmBHeT7oDHo3C

ralyodio and others added 2 commits September 13, 2026 07:59
…hole cadence

startRun pushes next_run_at a cadence forward before the run begins, and
a container that dies mid-run leaves that in place: the tick's reaper
marked the run abandoned but left the source parked. For a bulk list of
ten thousand pages read once a month, a redeploy in the wrong minute
meant a month with nothing to show. The reaper now asks the source to run
again at once (paused sources excepted), so the walk resumes from its
cursor at the next tick. Two tests against the in-process Postgres.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwAoNvWzezmBHeT7oDHo3C
@ralyodio
ralyodio merged commit 2dd4fe5 into main Sep 13, 2026
@ralyodio
ralyodio deleted the stale-run-requeue branch September 13, 2026 08:00
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