Skip to content

workflow: recover stranded local runs on restart#131

Draft
msullivan wants to merge 1 commit into
retryloopfrom
recover
Draft

workflow: recover stranded local runs on restart#131
msullivan wants to merge 1 commit into
retryloopfrom
recover

Conversation

@msullivan

Copy link
Copy Markdown
Contributor

A sleep persists a wait and schedules a delayed queue message to wake it. Under vercel dev that message lives in an in-memory queue, so restarting the dev server mid-run loses the wake-up and strands the run in running.

On dev worker startup, LocalWorld now re-enqueues every non-terminal run, retrying via RetryLoop until the dev queue is reachable; workflow_handler turns any elapsed wait into a wait_completed and continues. Replay is idempotent, so this should be fine?

@vercel

vercel Bot commented Jun 16, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
vercel-py Ready Ready Preview Jun 16, 2026 12:39am

Request Review

A sleep persists a wait and schedules a delayed queue message to wake it.
Under `vercel dev` that message lives in an in-memory queue, so restarting
the dev server mid-run loses the wake-up and strands the run in `running`.

On dev worker startup, LocalWorld now re-enqueues every non-terminal
run, retrying via RetryLoop until the dev queue is reachable;
workflow_handler turns any elapsed wait into a wait_completed and
continues. Replay is idempotent, so this should be fine?
@fantix

fantix commented Jun 16, 2026

Copy link
Copy Markdown
Member

Yeah I think this is good; I'm working on implementing the local queue out of vercel dev but it would also be an in-memory queue, so this will be still needed.

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.

2 participants