Skip to content

Preserve pending debounce ownership during job recovery - #231

Merged
iamwavecut merged 1 commit into
mainfrom
fix/taskman-recovery-debounce
Oct 10, 2026
Merged

iamwavecut merged 1 commit into
mainfrom
fix/taskman-recovery-debounce

Conversation

@iamwavecut

Copy link
Copy Markdown
Owner

After an interrupted job, startup recovery can requeue it while a newer pending job already owns the same queue/debounce key. Persisting the recovered record then violates the partial unique index and prevents the bot from starting.

Keep the newer pending job as the coalescing target and clear the conflicting debounce key only on the recovered record. Preserve both jobs, their payloads, lane keys, and checkpoints. Apply the same reset to orphan startup recovery, general startup requeue, and expired-processing recovery. Uncontested keys remain unchanged; agent processing runs retain their existing resume behavior.

Validation: regression reproduced before the fix; all three recovery paths now retain and dequeue both requests in order. A second case verifies that the same key in another queue does not cause detachment. Workspace/all-target tests: 2,475 passed, 10 ignored. Formatting and workspace/all-target Clippy with warnings denied passed.

@github-actions

Copy link
Copy Markdown
Messages
📖 Danger checked 1 changed file(s).

Generated by 🚫 dangerJS against 9d20864

@iamwavecut
iamwavecut merged commit 5b6ee14 into main Oct 10, 2026
12 checks passed
@iamwavecut
iamwavecut deleted the fix/taskman-recovery-debounce branch October 10, 2026 13:54
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