Skip to content

Backport #2888: Fix namespaced active run recovery - #2889

Merged
VaguelySerious merged 3 commits into
stablefrom
backport/pr-2888-to-stable
Aug 24, 2026
Merged

Backport #2888: Fix namespaced active run recovery#2889
VaguelySerious merged 3 commits into
stablefrom
backport/pr-2888-to-stable

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Automated backport of #2888 to stable (backport job run).

AI recommendation: This is a self-contained bug fix for namespaced active-run recovery. All touched files (recovery.ts, world-postgres/src/index.ts, reenqueue.test.ts) and the helper APIs it relies on (getQueueTopicPrefix, resolveQueueNamespace) already exist on stable, and recovery.ts matches the exact pre-image blob on stable, so the fix applies without depending on any main-only behavior.

Merge conflicts were resolved by AI (opencode with anthropic/claude-opus-4.8). Please review the conflict resolution carefully before merging.

Signed-off-by: Casey Gowrie <ctgowrie@gmail.com>
Signed-off-by: Casey Gowrie <casey.gowrie@vercel.com>
@github-actions
github-actions Bot requested review from a team and ijjk as code owners July 12, 2026 22:29
@github-actions github-actions Bot mentioned this pull request Jul 12, 2026
3 tasks
@changeset-bot

changeset-bot Bot commented Jul 12, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 29542a3

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 20 packages
Name Type
@workflow/world Patch
@workflow/world-local Patch
@workflow/world-postgres Patch
@workflow/cli Patch
@workflow/core Patch
@workflow/vitest Patch
@workflow/web-shared Patch
@workflow/web Patch
@workflow/world-testing Patch
@workflow/world-vercel Patch
workflow Patch
@workflow/builders Patch
@workflow/next Patch
@workflow/nitro Patch
@workflow/astro Patch
@workflow/nest Patch
@workflow/rollup Patch
@workflow/sveltekit Patch
@workflow/vite Patch
@workflow/nuxt Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel

vercel Bot commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

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

Project Deployment Actions Updated (UTC)
example-nextjs-workflow-turbopack Ready Ready Preview, v0 Aug 24, 2026 11:06pm
example-nextjs-workflow-webpack Ready Ready Preview, v0 Aug 24, 2026 11:06pm
example-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-astro-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-express-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-fastify-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-hono-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-nestjs-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-nitro-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-nuxt-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-python-workflow Error Error v0 Aug 24, 2026 11:06pm
workbench-sveltekit-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-tanstack-start-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workbench-vite-workflow Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workflow-swc-playground Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workflow-tarballs Ready Ready Preview, v0 Aug 24, 2026 11:06pm
workflow-web Ready Ready Preview, v0 Aug 24, 2026 11:06pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
workflow-docs Skipped Skipped v0 Aug 24, 2026 11:06pm

@github-actions

github-actions Bot commented Jul 12, 2026

Copy link
Copy Markdown
Contributor Author

🧪 E2E Test Results

Some tests failed

Summary

Passed Failed Skipped Total
✅ ▲ Vercel Production 1099 0 78 1177
✅ 💻 Local Development 1198 0 86 1284
✅ 📦 Local Production 1198 0 86 1284
✅ 🐘 Local Postgres 1198 0 86 1284
✅ 🪟 Windows 107 0 0 107
❌ 🌍 Community Worlds 82 106 9 197
✅ 📋 Other 606 0 36 642
Total 5488 106 381 5975

❌ Failed Tests

🌍 Community Worlds (106 failed)

redis (21 failed):

  • hookWorkflow | wrun_01M0V09DHFCR3CWR7YMX2XJ8XN
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01M0V09M5H7VDSB4GG618AVTS0
  • parallelStepsThenWebhookWorkflow - no hook_conflict from same-tick replay race | wrun_01M0V09Y0VJ5WFMN1YDW7E6MCE
  • sleepingWorkflow | wrun_01M0V0ATRABH66DBZ61GYDJNJK
  • outputStreamWorkflow negative startIndex (reads from end)
  • outputStreamWorkflow - getTailIndex and getStreamChunks getTailIndex returns correct index after stream completes
  • outputStreamWorkflow - getTailIndex and getStreamChunks getTailIndex returns -1 before any chunks are written
  • outputStreamWorkflow - getTailIndex and getStreamChunks getStreamChunks returns same content as reading the stream
  • error handling serialization failures step-argument serialization failure is catchable in workflow code
  • error handling serialization failures uncaught step-argument serialization failure fails the run as USER_ERROR without redelivery retries
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01M0V0JPP1D68JABGKV9N1N6B4
  • hookGetConflictWorkflow - awaiting hook.getConflict() registers hook without payload | wrun_01M0V0K2CZ9HYR6Q2YYXNRYQ5D
  • hookGetConflictThenStepParallelWorkflow - hook.getConflict() continuation step runs alongside other steps | wrun_01M0V0K9NYNYM4ESXJHM95SE1N
  • hookGetConflictWorkflow - hook.getConflict() resolves with the conflicting run when token is already registered | wrun_01M0V0KR5AF42E5WF4ZWBXQDRF
  • hookClaimOnlyMutexWorkflow - hook works as a pure run mutex without payload data | wrun_01M0V0MHQQWV1XZY9Y45B7NTNW
  • hookAdoptOwnerResultWorkflow - duplicate adopts the owner result via conflict.returnValue | wrun_01M0V0MNH4437BT0ACHFFCKYN0
  • hookSignalOwnerWorkflow - duplicate forwards its payload to the owner via resumeHook | wrun_01M0V0MV3JHMBHH7WWADM9KKGV
  • hookSupersedeOwnerWorkflow - duplicate cancels the owner and claims the released token | wrun_01M0V0N09QR3EEXR31TE9SJF1Y
  • resume-or-start route pattern - resumeHook retried after start() reaches the new run | wrun_01M0V0N8HGSG63H82JE7DKBJDD
  • pages router sleepingWorkflow via pages router
  • resilient start: addTenWorkflow completes when run_created returns 500 | wrun_01M0V0TKSZNRFXWN8378JDT4B6

turso (85 failed):

  • addTenWorkflow | wrun_01M0V08G92ED1Y1BD1G2FBPS87
  • addTenWorkflow | wrun_01M0V08G92ED1Y1BD1G2FBPS87
  • deploymentId: 'latest' is a no-op in non-Vercel worlds
  • wellKnownAgentWorkflow (.well-known/agent) | wrun_01M0V098T8PD8VZE7QZW84085G
  • should work with react rendering in step
  • promiseAllWorkflow | wrun_01M0V08Q84G390WPK93YKH0MTR
  • promiseRaceWorkflow | wrun_01M0V08WTG12QHYSV54XCZF9MC
  • promiseAnyWorkflow | wrun_01M0V08YVH4CWV4PE303KAAP1Z
  • importedStepOnlyWorkflow | wrun_01M0V09KY3V3G3MRM0GKY1R6Y9
  • readableStreamWorkflow | wrun_01M0V090XA9KTND89K9HVMM2M0
  • hookWorkflow | wrun_01M0V09DHFCR3CWR7YMX2XJ8XN
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01M0V09M5H7VDSB4GG618AVTS0
  • webhookWorkflow | wrun_01M0V09RQYTTXTSNHDC6SQXNSA
  • parallelStepsThenWebhookWorkflow - no hook_conflict from same-tick replay race | wrun_01M0V09Y0VJ5WFMN1YDW7E6MCE
  • sleepingWorkflow | wrun_01M0V0ATRABH66DBZ61GYDJNJK
  • parallelSleepWorkflow | wrun_01M0V0BAJWQJBQYNPPWBVGXDG2
  • sleepWinsRaceWorkflow | wrun_01M0V0BDYERSSS7NB0GVJ72588
  • stepWinsRaceWorkflow | wrun_01M0V0BHB3SSDDJ25RP0B2791C
  • nullByteWorkflow | wrun_01M0V0BMKK3C62YYP9SZG4ZF7W
  • workflowAndStepMetadataWorkflow | wrun_01M0V0BQ21CZN33YT0VKPE0697
  • outputStreamWorkflow no startIndex (reads all chunks)
  • outputStreamWorkflow positive startIndex (skips first chunk)
  • outputStreamWorkflow negative startIndex (reads from end)
  • outputStreamWorkflow - getTailIndex and getStreamChunks getTailIndex returns correct index after stream completes
  • outputStreamWorkflow - getTailIndex and getStreamChunks getTailIndex returns -1 before any chunks are written
  • outputStreamWorkflow - getTailIndex and getStreamChunks getStreamChunks returns same content as reading the stream
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions | wrun_01M0V0DXD3M59P397FBQFXE560
  • writableForwardedFromWorkflowWorkflow | wrun_01M0V0EAR1RQBRWE3QY1QC15S9
  • writableForwardedFromStepWorkflow | wrun_01M0V0EERSB9PJ9R870ATPZ8J5
  • fetchWorkflow | wrun_01M0V0EJ6MQ8YBK1WVG192RFMN
  • promiseRaceStressTestWorkflow | wrun_01M0V0ENGKTM80AQQT706D7Q44
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • error handling serialization failures step-argument serialization failure is catchable in workflow code
  • error handling serialization failures uncaught step-argument serialization failure fails the run as USER_ERROR without redelivery retries
  • error handling not registered WorkflowNotRegisteredError fails the run when workflow does not exist
  • error handling not registered StepNotRegisteredError fails the step but workflow can catch it
  • error handling not registered StepNotRegisteredError fails the run when not caught in workflow
  • hookCleanupTestWorkflow - hook token reuse after workflow completion | wrun_01M0V0JAYDSRT7DVHEB7JYFGWA
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01M0V0JPP1D68JABGKV9N1N6B4
  • hookGetConflictWorkflow - awaiting hook.getConflict() registers hook without payload | wrun_01M0V0K2CZ9HYR6Q2YYXNRYQ5D
  • 'hookGetConflictWithPriorStepWorkflow' - hook.getConflict() does not block step execution | wrun_01M0V0K4XNV1FQGZT39S784NFF
  • 'hookGetConflictWithParallelStepWorkfl…' - hook.getConflict() does not block step execution | wrun_01M0V0K75SBJ66V4YV8QQWDKNX
  • hookGetConflictThenStepParallelWorkflow - hook.getConflict() continuation step runs alongside other steps | wrun_01M0V0K9NYNYM4ESXJHM95SE1N
  • hookGetConflictWorkflow - hook.getConflict() resolves with the conflicting run when token is already registered | wrun_01M0V0KR5AF42E5WF4ZWBXQDRF
  • hookClaimOnlyMutexWorkflow - hook works as a pure run mutex without payload data | wrun_01M0V0MHQQWV1XZY9Y45B7NTNW
  • hookAdoptOwnerResultWorkflow - duplicate adopts the owner result via conflict.returnValue | wrun_01M0V0MNH4437BT0ACHFFCKYN0
  • hookSignalOwnerWorkflow - duplicate forwards its payload to the owner via resumeHook | wrun_01M0V0MV3JHMBHH7WWADM9KKGV
  • hookSupersedeOwnerWorkflow - duplicate cancels the owner and claims the released token | wrun_01M0V0N09QR3EEXR31TE9SJF1Y
  • resume-or-start route pattern - resumeHook retried after start() reaches the new run | wrun_01M0V0N8HGSG63H82JE7DKBJDD
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_01M0V0NG01N4J5DHCVRCDJDZ5X
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) | wrun_01M0V0NZ9E29JEV27RM4MRZPM9
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument | wrun_01M0V0P82RR7ZG9B6TS6FRYY7P
  • closureVariableWorkflow - nested step functions with closure variables | wrun_01M0V0PDKKGX2PP4WVVPM7RTHT
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step | wrun_01M0V0PFZFTMFGQ7QJ7W16RPAW
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • health check (CLI) - workflow health command reports healthy endpoints
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly | wrun_01M0V0PYMB4XV7YG207VDZT2VG
  • Calculator.calculate - static workflow method using static step methods from another class | wrun_01M0V0Q41QQCJYRSGD4TDT78A6
  • AllInOneService.processNumber - static workflow method using sibling static step methods | wrun_01M0V0Q9FBNF3RN808WRAX3YTT
  • ChainableService.processWithThis - static step methods using this to reference the class | wrun_01M0V0QFZ1XD9MD7XTWMB91KE3
  • thisSerializationWorkflow - step function invoked with .call() and .apply() | wrun_01M0V0QPF357SNV5KVM4F0HK13
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE | wrun_01M0V0QX0YHXJ7NXA023SNQQD3
  • instanceMethodStepWorkflow - instance methods with "use step" directive | wrun_01M0V0R4M7TENG957ZBTAA1Q18
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context | wrun_01M0V0RGGGB8M090T7PP5NCZG0
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument | wrun_01M0V0RRB4JYBMP68TD4HPE9RJ
  • cancelRun - cancelling a running workflow | wrun_01M0V0RYVR48YJXEGGHEBJVS3D
  • cancelRun via CLI - cancelling a running workflow | wrun_01M0V0S3DGTMRARXY12MEM2M8E
  • pages router addTenWorkflow via pages router
  • pages router promiseAllWorkflow via pages router
  • pages router sleepingWorkflow via pages router
  • hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep | wrun_01M0V0SAWXY3V0RJ8AFDFYEHA7
  • hookWithSleepFinalStepWorkflow - step only on final payload | wrun_01M0V0SPAVESEZJ2ETETGDAB66
  • sleepInLoopWorkflow - sleep inside loop with steps actually delays each iteration | wrun_01M0V0SYTSBSQEK9WD71XYGFNB
  • sleepWithSequentialStepsWorkflow - sequential steps work with concurrent sleep (control) | wrun_01M0V0T8ZF6X909JWYF0BEDM0W
  • importMetaUrlWorkflow - import.meta.url is available in step bundles | wrun_01M0V0TFCVYVWS0T8BBP78RFBK
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) | wrun_01M0V0THHV2R2GB4QDXFBSB3KV
  • resilient start: addTenWorkflow completes when run_created returns 500 | wrun_01M0V0TKSZNRFXWN8378JDT4B6

Details by Category

✅ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 99 0 8
✅ example 99 0 8
✅ express 99 0 8
✅ fastify 99 0 8
✅ hono 99 0 8
✅ nextjs-turbopack 104 0 3
✅ nextjs-webpack 104 0 3
✅ nitro 99 0 8
✅ nuxt 99 0 8
✅ sveltekit 99 0 8
✅ vite 99 0 8
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 101 0 6
✅ express-stable 101 0 6
✅ fastify-stable 101 0 6
✅ hono-stable 101 0 6
✅ nextjs-turbopack-canary 88 0 19
✅ nextjs-turbopack-stable 107 0 0
✅ nextjs-webpack-canary 88 0 19
✅ nextjs-webpack-stable 107 0 0
✅ nitro-stable 101 0 6
✅ nuxt-stable 101 0 6
✅ sveltekit-stable 101 0 6
✅ vite-stable 101 0 6
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 101 0 6
✅ express-stable 101 0 6
✅ fastify-stable 101 0 6
✅ hono-stable 101 0 6
✅ nextjs-turbopack-canary 88 0 19
✅ nextjs-turbopack-stable 107 0 0
✅ nextjs-webpack-canary 88 0 19
✅ nextjs-webpack-stable 107 0 0
✅ nitro-stable 101 0 6
✅ nuxt-stable 101 0 6
✅ sveltekit-stable 101 0 6
✅ vite-stable 101 0 6
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 101 0 6
✅ express-stable 101 0 6
✅ fastify-stable 101 0 6
✅ hono-stable 101 0 6
✅ nextjs-turbopack-canary 88 0 19
✅ nextjs-turbopack-stable 107 0 0
✅ nextjs-webpack-canary 88 0 19
✅ nextjs-webpack-stable 107 0 0
✅ nitro-stable 101 0 6
✅ nuxt-stable 101 0 6
✅ sveltekit-stable 101 0 6
✅ vite-stable 101 0 6
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 107 0 0
❌ 🌍 Community Worlds
App Passed Failed Skipped
✅ mongodb-dev 4 0 3
✅ redis-dev 4 0 3
❌ redis 67 21 0
✅ turso-dev 4 0 3
❌ turso 3 85 0
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 101 0 6
✅ e2e-local-dev-tanstack-start-stable 101 0 6
✅ e2e-local-postgres-nest-stable 101 0 6
✅ e2e-local-postgres-tanstack-start-stable 101 0 6
✅ e2e-local-prod-nest-stable 101 0 6
✅ e2e-local-prod-tanstack-start-stable 101 0 6

📋 View full workflow run

@VaguelySerious
VaguelySerious enabled auto-merge (squash) July 12, 2026 22:37
The backport carried over main's factory name. On stable the local world
factory is exported as createLocalWorld, so the new test threw
ReferenceError: createWorld is not defined.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@vercel
vercel Bot temporarily deployed to Preview – workflow-docs August 24, 2026 23:02 Inactive
@VaguelySerious
VaguelySerious merged commit 699e01e into stable Aug 24, 2026
93 of 97 checks passed
@VaguelySerious
VaguelySerious deleted the backport/pr-2888-to-stable branch August 24, 2026 23:20
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