Skip to content

[world-vercel] Resume partial replay streams after validated events - #3546

Open
NathanColosimo wants to merge 8 commits into
mainfrom
codex/replay-stream-recovery
Open

[world-vercel] Resume partial replay streams after validated events#3546
NathanColosimo wants to merge 8 commits into
mainfrom
codex/replay-stream-recovery

Conversation

@NathanColosimo

@NathanColosimo NathanColosimo commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add an optional synchronous event-stream observer that runs after each frame validates
  • make run-started, lazy-hook, and full-list responses continue from the last accepted event after a transport interruption
  • handle a clean partial sentinel and a truncated body through the same cursor continuation path
  • preserve the last accepted cursor when an empty continuation completes the replay log
  • classify only decoder iteration failures as transport truncation; validation and observer failures still propagate
  • keep replay events locally owned and remove the extra generator and six-argument list wrapper

Review scope

This is the transport substrate only. It does not decrypt or prepare payloads. The next layers consume the observer introduced here.

Stack

  1. [world-vercel] Decode chunked event frames without repeated copies #3586 — linear frame-buffer refill
  2. [world-vercel] Resume partial replay streams after validated events #3546 — replay stream recovery
  3. [core] Decode replay payloads synchronously #3547 — synchronous replay decode
  4. [core] Prepare replay payloads as event frames arrive #3548 — streamed replay preparation
  5. [core] Trace fresh workflow replay phases #3523 — replay phase tracing
  6. [core] Prune schema modules from workflow bundles #3550 — prune sandbox dependency graph
  7. [workflow] Load per-source replay bundles #3551 — per-source lazy VM bundles
  8. [core] Retain workflow VMs across hooks #3576 — retain workflow VMs across hooks

Validation

  • pnpm --filter @workflow/world-vercel... build
  • pnpm --filter @workflow/world-vercel test — 518 tests passed
  • pnpm --filter @workflow/world-vercel typecheck
  • Biome and git diff --check

@changeset-bot

changeset-bot Bot commented Aug 14, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 92aae4c

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-vercel Patch
@workflow/cli Patch
@workflow/core Patch
@workflow/vitest Patch
@workflow/web-shared Patch
@workflow/web Patch
@workflow/world-local Patch
@workflow/world-postgres Patch
@workflow/world-testing 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 Aug 14, 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 Aug 20, 2026 5:39pm
example-nextjs-workflow-webpack Ready Ready Preview Aug 20, 2026 5:39pm
example-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-astro-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-express-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-fastify-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-hono-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-nestjs-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-nitro-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-nuxt-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-python-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-sveltekit-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-tanstack-start-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workbench-vite-workflow Ready Ready Preview Aug 20, 2026 5:39pm
workflow-docs Ready Ready Preview, v0 Aug 20, 2026 5:39pm
workflow-swc-playground Ready Ready Preview Aug 20, 2026 5:39pm
workflow-tarballs Ready Ready Preview Aug 20, 2026 5:39pm
workflow-web Ready Ready Preview Aug 20, 2026 5:39pm

@github-actions

github-actions Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

Some tests failed

❌ Failed E2E Tests

▲ Vercel Production (50 failed)

astro-node (1 failed):

  • hookAdoptOwnerResultWorkflow - duplicate adopts the owner result via conflict.returnValue | wrun_41M0G484ZK0GYGJ40HA6DV0JRS | 🔍 observability

astro-quickjs (1 failed):

  • setAttributes start: initial attributes are seeded on run creation

example-node (8 failed):

  • parallelStepsThenWebhookWorkflow - no hook_conflict from same-tick replay race | wrun_41M0G4739F0GQK912RD80EH6X5 | 🔍 observability
  • hookCleanupTestWorkflow - hook token reuse after workflow completion | wrun_41M0G470WA0GY55YD0WQPYVPR4 | 🔍 observability
  • AbortController abortThrowIfAbortedMidFlightWorkflow: throwIfAborted in a polling loop bails when abort fires
  • AbortController abortDeterministicBranchFromStepWorkflow: branches stay consistent when abort comes from a step
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) | wrun_41M0G4CW420GT32Q8DWFSTGWFN | 🔍 observability
  • setAttributes Promise.all of disjoint-key writes: every key lands
  • setAttributes workflow throws after awaited setAttributes: attribute still persists on the failed run
  • setAttributes validation DX: invalid writes throw catchable FatalErrors naming rule and limit

example-quickjs (2 failed):

  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_41M0G48X2H0GK4SJGPAHEMRTZZ | 🔍 observability
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly | wrun_41M0G4A68F0GZ0MRXQJXSJJPGR | 🔍 observability

fastify-quickjs (5 failed):

  • outputStreamInsideStepWorkflow - getWritable() called inside step functions | wrun_41M0G42XEV0GK0AXVD0DDJGJH7 | 🔍 observability
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_41M0G48X2H0GK4SJGPAHEMRTZZ | 🔍 observability
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context | wrun_41M0G4BPN30GSBXVSDCVNV7S30 | 🔍 observability
  • cancelRun via CLI - cancelling a running workflow | wrun_41M0G3YEAB0GT7Q40NP7TW1AHJ | 🔍 observability

hono-node (2 failed):

  • error handling serialization failures uncaught step-argument serialization failure fails the run as USER_ERROR without redelivery retries
  • hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep | wrun_41M0G4C5SK0GJE7GNXAH2EDA5Y | 🔍 observability

hono-quickjs (1 failed):

  • AbortController abortAnyInWorkflowWorkflow: AbortSignal.any composes signals inside the workflow VM

nest-node (1 failed):

  • error handling catchability workflow throw of a non-Error value round-trips verbatim as cause

nextjs-turbopack-node (1 failed):

  • wellKnownAgentWorkflow (.well-known/agent) | wrun_41M0G41QDX0GNET969FKEPQ7A8 | 🔍 observability

nextjs-turbopack-quickjs (1 failed):

  • DurableAgent e2e tool approval (GAP) completes but needsApproval is not checked (GAP)

nextjs-webpack-node (2 failed):

  • error handling error propagation step errors basic step error preserves message and stack trace
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step | wrun_41M0G49HQP0GPRBRCFQDV7PXEX | 🔍 observability

nextjs-webpack-quickjs (1 failed):

  • AbortController abortReasonTypesWorkflow: various abort reason types propagate correctly

nitro-node (1 failed):

  • outputStreamWorkflow negative startIndex (reads from end)

nitro-quickjs (1 failed):

  • hookWorkflow is not resumable via public webhook endpoint | wrun_41M0G439880GJC6D20F6N9NY38 | 🔍 observability

nuxt-node (4 failed):

  • outputStreamWorkflow no startIndex (reads all chunks)
  • AbortController abortThrowIfAbortedWorkflow: throwIfAborted causes FatalError, no retries
  • AbortController abortFetchUncaughtWorkflow: uncaught fetch AbortError is FatalError, no retries
  • AbortController abortVoidSleepTimeoutWorkflow: documented void sleep().then(abort) pattern works

nuxt-quickjs (3 failed):

  • error handling catchability step throw round-trips FatalError with cause chain to workflow catch
  • error handling catchability step throw of a non-Error value preserves it as cause on the wrapping FatalError
  • hookTokenReuseLoopWorkflow - same run recreates a hook with the same token after dispose() | wrun_41M0G48TRS0GZDW5M90ZMAJ02H | 🔍 observability

sveltekit-node (3 failed):

  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_41M0G46SZQ0GP40DRS852JF4F6 | 🔍 observability
  • hookClaimOnlyMutexWorkflow - hook works as a pure run mutex without payload data | wrun_41M0G48AZ90GS16EYAPWYDD3YH | 🔍 observability
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_41M0G48X2H0GK4SJGPAHEMRTZZ | 🔍 observability

sveltekit-quickjs (5 failed):

  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument | wrun_41M0G49AYC0GK6QZ1VFFD08W7P | 🔍 observability
  • importMetaUrlWorkflow - import.meta.url is available in step bundles | wrun_41M0G4CW0W0GJV554N6P8RMC0J | 🔍 observability
  • setAttributes fire-and-forget: void setAttributes lands without awaiting
  • setAttributes Promise.all of disjoint-key writes: every key lands
  • setAttributes validation DX: invalid writes throw catchable FatalErrors naming rule and limit

tanstack-start-node (1 failed):

  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument | wrun_41M0G4BTQW0GRPPD10Y071SVM8 | 🔍 observability

tanstack-start-quickjs (1 failed):

  • AbortController abortAlreadyAbortedWorkflow: pre-aborted signal seen by step

vite-node (3 failed):

  • error handling retry behavior regular Error retries until success
  • hookGetConflictWorkflow - hook.getConflict() resolves with the conflicting run when token is already registered | wrun_41M0G47GQE0GZHTJW94PQVNB0K | 🔍 observability
  • hookClaimOnlyMutexWorkflow - hook works as a pure run mutex without payload data | wrun_41M0G48AZ90GS16EYAPWYDD3YH | 🔍 observability

vite-quickjs (2 failed):

  • hookGetConflictWorkflow - hook.getConflict() resolves with the conflicting run when token is already registered | wrun_41M0G47GQE0GZHTJW94PQVNB0K | 🔍 observability
  • AbortController abortHookOrderingWorkflow [listener-first-hook-first]: addEventListener → hook.then → resumeHook → abort()

⚠️ Flaky E2E Tests (passed on retry)

These tests failed at least once and passed on a retry. A recurring entry here is a real race worth investigating.

110 flaky tests
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously (nextjs-webpack) — flaked in 2 jobs
  • 'hookGetConflictWithParallelStepWorkfl…' - hook.getConflict() does not block step execution (nextjs-webpack)
  • 'hookGetConflictWithPriorStepWorkflow' - hook.getConflict() does not block step execution (example)
  • 'hookGetConflictWithPriorStepWorkflow' - hook.getConflict() does not block step execution (nitro)
  • abortAfterCompletionWorkflow: abort after step completes is a no-op (fastify)
  • abortDeterministicBranchFromStepWorkflow: branches stay consistent when abort comes from a step (nest)
  • abortExternalSignalWorkflow: signal passed as workflow input (astro)
  • abortExternalSignalWorkflow: signal passed as workflow input (nitro)
  • abortFetchInFlightWorkflow: aborting cancels an in-flight fetch (nest)
  • abortHookOrderingWorkflow [hook-first-abort-first]: hook.then → addEventListener → abort() → resumeHook (astro)
  • abortHookOrderingWorkflow [hook-first-abort-first]: hook.then → addEventListener → abort() → resumeHook (nuxt)
  • abortHookOrderingWorkflow [hook-first-hook-first]: hook.then → addEventListener → resumeHook → abort() (astro)
  • abortHookOrderingWorkflow [hook-first-hook-first]: hook.then → addEventListener → resumeHook → abort() (example)
  • abortHookOrderingWorkflow [hook-first-hook-first]: hook.then → addEventListener → resumeHook → abort() (tanstack-start)
  • abortHookOrderingWorkflow [listener-first-abort-first]: addEventListener → hook.then → abort() → resumeHook (astro)
  • abortHookOrderingWorkflow [listener-first-abort-first]: addEventListener → hook.then → abort() → resumeHook (nest)
  • abortHookOrderingWorkflow [listener-first-abort-first]: addEventListener → hook.then → abort() → resumeHook (nuxt)
  • abortHookOrderingWorkflow [listener-first-hook-first]: addEventListener → hook.then → resumeHook → abort() (astro)
  • abortHookOrderingWorkflow [listener-first-hook-first]: addEventListener → hook.then → resumeHook → abort() (example)
  • abortHookOrderingWorkflow [listener-first-hook-first]: addEventListener → hook.then → resumeHook → abort() (nuxt)
  • abortParallelWorkflow: abort cancels all parallel steps (example)
  • abortReasonWorkflow: abort reason preserved across boundaries (nextjs-webpack)
  • abortThrowIfAbortedWorkflow: throwIfAborted causes FatalError, no retries (nextjs-turbopack)
  • abortVoidSleepTimeoutWorkflow: documented void sleep().then(abort) pattern works (fastify)
  • addTenWorkflow (nextjs-turbopack)
  • addTenWorkflow (nitro)
  • addTenWorkflow (tanstack-start)
  • AllInOneService.processNumber - static workflow method using sibling static step methods (nextjs-turbopack)
  • basic step error preserves message and stack trace (astro)
  • Calculator.calculate - static workflow method using static step methods from another class (nitro)
  • cancelRun - cancelling a running workflow (nextjs-webpack)
  • cancelRun via CLI - cancelling a running workflow (express)
  • cancelRun via CLI - cancelling a running workflow (fastify)
  • cancelRun via CLI - cancelling a running workflow (nextjs-turbopack)
  • completes but callbacks are not called (GAP) (nextjs-turbopack)
  • completes but prepareCall is not applied (GAP) (nextjs-turbopack)
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously (example)
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously (express)
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE (nextjs-turbopack)
  • errorSubclassRoundTripWorkflow - first-class Error subclasses survive every serialization boundary (example)
  • FatalError fails immediately without retries (example)
  • fetchWorkflow (example)
  • fetchWorkflow (nextjs-webpack)
  • getChunks returns same content as reading the stream (nextjs-webpack)
  • getTailIndex returns -1 before any chunks are written (nuxt)
  • getTailIndex returns correct index after stream completes (hono)
  • getterStepWorkflow - getter functions with "use step" directive (express)
  • hookAdoptOwnerResultWorkflow - duplicate adopts the owner result via conflict.returnValue (astro)
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running (fastify)
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running (tanstack-start)
  • hookGetConflictThenStepParallelWorkflow - hook.getConflict() continuation step runs alongside other steps (astro)
  • hookGetConflictThenStepParallelWorkflow - hook.getConflict() continuation step runs alongside other steps (express)
  • hookGetConflictWorkflow - awaiting hook.getConflict() registers hook without payload (example)
  • hookGetConflictWorkflow - awaiting hook.getConflict() registers hook without payload (express)
  • hookGetConflictWorkflow - awaiting hook.getConflict() registers hook without payload (nextjs-webpack)
  • hookSupersedeOwnerWorkflow - duplicate cancels the owner and claims the released token (nextjs-webpack)
  • hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep (tanstack-start)
  • hookWorkflow (example)
  • hookWorkflow (express)
  • hookWorkflow (nest)
  • hookWorkflow (nuxt)
  • instanceMethodStepWorkflow - instance methods with "use step" directive (nextjs-webpack)
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) (astro)
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) (hono)
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) (nest)
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) (nuxt)
  • negative startIndex (reads from end) (express)
  • no startIndex (reads all chunks) (example)
  • no startIndex (reads all chunks) (nest)
  • outputStreamInsideStepWorkflow - getWritable() called inside step functions (fastify)
  • parallelStepsThenWebhookWorkflow - no hook_conflict from same-tick replay race (nitro)
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly (nextjs-turbopack)
  • positive startIndex (skips first chunk) (nextjs-turbopack)
  • positive startIndex (skips first chunk) (nitro)
  • Promise.all of disjoint-key writes: every key lands (express)
  • Promise.all of disjoint-key writes: every key lands (fastify)
  • Promise.all of disjoint-key writes: every key lands (nextjs-webpack)
  • promiseAnyWorkflow (astro)
  • promiseRaceWorkflow (hono)
  • provider tool identity preserved across step boundaries (nextjs-turbopack)
  • readableStreamWorkflow (hono)
  • regular Error retries until success (nextjs-turbopack)
  • retainedInterleavingWorkflow (nextjs-webpack)
  • runClassSerializationWorkflow - Run instances serialize across workflow/step boundaries (example)
  • runClassSerializationWorkflow - Run instances serialize across workflow/step boundaries (nuxt)
  • setAttributesInsideStepWorkflow: step-body calls append attributed native events (astro)
  • sleepingWorkflow (example)
  • sleepInLoopWorkflow - sleep inside loop with steps actually delays each iteration (hono)
  • sleepWinsRaceWorkflow (hono)
  • step throw of a non-Error value preserves it as cause on the wrapping FatalError (nitro)
  • step throw round-trips FatalError with cause chain to workflow catch (nextjs-webpack)
  • step-argument serialization failure is catchable in workflow code (nitro)
  • step-return-value serialization failure is catchable in workflow code (express)
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument (nest)
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument (tanstack-start)
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) (nest)
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) (nextjs-webpack)
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) (nitro)
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) (tanstack-start)
  • StepNotRegisteredError fails the run when not caught in workflow (fastify)
  • stepWinsRaceWorkflow (fastify)
  • stepWinsRaceWorkflow (nuxt)
  • stream-level prepareStep overrides constructor-level (nextjs-turbopack)
  • thisSerializationWorkflow - step function invoked with .call() and .apply() (astro)
  • thisSerializationWorkflow - step function invoked with .call() and .apply() (nitro)
  • webhookWorkflow (nextjs-webpack)
  • workflow throw of a non-Error value round-trips verbatim as cause (example)
  • workflow throw of a non-Error value round-trips verbatim as cause (tanstack-start)
  • workflow throw round-trips FatalError + cause through run_failed event (express)
  • workflow throw round-trips FatalError + cause through run_failed event (nitro)

🛠 Infra Events (absorbed by the harness)

Platform anomalies the e2e harness detected and worked around (e.g. a run the queue never picked up, replaced by a fresh run). Clustered timestamps indicate a backend blip; a steady drip indicates a platform issue worth escalating.

  • cold-start-warmup · suite warmup (tanstack-start) · at 17:43:26Z · abandoned wrun_01M0G49Q5D2AKDGMNSK6YXG04B
  • run-pickup-stall · cancelRun - cancelling a running workflow (fastify) · at 17:45:06Z · abandoned wrun_41M0G4AVWR0GRFJXVD9DR5HD6B
  • run-pickup-stall · setAttributesInsideStepWorkflow: step-body calls append attributed native events (tanstack-start) · at 17:48:04Z · abandoned wrun_41M0G4F0DP0GWY2XBPZWXYYFT8
  • run-pickup-stall · plainModuleDoneHook resumed via plain API route (o2flow shape) (nextjs-webpack) · at 17:51:16Z · abandoned wrun_01M0G4RE1YYAFQ04JR4TVQ1WR6
  • run-pickup-stall · hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep (nextjs-webpack) · at 17:52:01Z · abandoned wrun_01M0G4ST5HDPK0VE4JX8C4T67A
  • run-pickup-stall · hookWithSleepFinalStepWorkflow - step only on final payload (nextjs-webpack) · at 17:52:07Z · abandoned wrun_01M0G4T0MRMBX8RCXYJ91V86S0
  • run-pickup-stall · plainModuleDoneHook resumed via plain API route (o2flow shape) (nextjs-webpack) · at 17:52:09Z · abandoned wrun_01M0G4T20GSVQPQNK3A00J6ZEC
  • run-pickup-stall · spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step (nextjs-webpack) · at 17:52:12Z · abandoned wrun_01M0G4T4YNQPDNZ1E4X7RF4VXR

E2E Test Summary

Summary
Passed Failed Skipped Total
❌ ▲ Vercel Production 3528 50 742 4320
✅ 💻 Local Development 3922 0 558 4480
✅ 📦 Local Production 3922 0 558 4480
✅ 🐘 Local Postgres 3922 0 558 4480
✅ 🪟 Windows 320 0 0 320
✅ 🌐 Cross-language Conformance 9 0 132 141
✅ vercel-multi-region 27 0 0 27
Total 15650 50 2548 18248
Details by Category

❌ ▲ Vercel Production

App Passed Failed Skipped
❌ astro-node 131 1 28
❌ astro-quickjs 131 1 28
❌ example-node 124 8 28
❌ example-quickjs 130 2 28
✅ express-node 132 0 28
✅ express-quickjs 132 0 28
✅ fastify-node 132 0 28
❌ fastify-quickjs 127 5 28
❌ hono-node 130 2 28
❌ hono-quickjs 131 1 28
❌ nest-node 131 1 28
✅ nest-quickjs 132 0 28
❌ nextjs-turbopack-node 156 1 3
❌ nextjs-turbopack-quickjs 156 1 3
❌ nextjs-webpack-node 155 2 3
❌ nextjs-webpack-quickjs 156 1 3
❌ nitro-node 131 1 28
❌ nitro-quickjs 131 1 28
❌ nuxt-node 128 4 28
❌ nuxt-quickjs 129 3 28
✅ python-node 8 0 152
❌ sveltekit-node 148 3 9
❌ sveltekit-quickjs 146 5 9
❌ tanstack-start-node 131 1 28
❌ tanstack-start-quickjs 131 1 28
❌ vite-node 129 3 28
❌ vite-quickjs 130 2 28

✅ 💻 Local Development

App Passed Failed Skipped
✅ astro-stable-node 134 0 26
✅ astro-stable-quickjs 134 0 26
✅ express-stable-node 134 0 26
✅ express-stable-quickjs 134 0 26
✅ fastify-stable-node 134 0 26
✅ fastify-stable-quickjs 134 0 26
✅ hono-stable-node 134 0 26
✅ hono-stable-quickjs 134 0 26
✅ nest-stable-node 134 0 26
✅ nest-stable-quickjs 134 0 26
✅ nextjs-turbopack-canary-node 141 0 19
✅ nextjs-turbopack-canary-quickjs 141 0 19
✅ nextjs-turbopack-stable-node 160 0 0
✅ nextjs-turbopack-stable-quickjs 160 0 0
✅ nextjs-webpack-canary-node 141 0 19
✅ nextjs-webpack-canary-quickjs 141 0 19
✅ nextjs-webpack-stable-node 160 0 0
✅ nextjs-webpack-stable-quickjs 160 0 0
✅ nitro-stable-node 134 0 26
✅ nitro-stable-quickjs 134 0 26
✅ nuxt-stable-node 134 0 26
✅ nuxt-stable-quickjs 134 0 26
✅ sveltekit-stable-node 153 0 7
✅ sveltekit-stable-quickjs 153 0 7
✅ tanstack-start-node 134 0 26
✅ tanstack-start-quickjs 134 0 26
✅ vite-stable-node 134 0 26
✅ vite-stable-quickjs 134 0 26

✅ 📦 Local Production

App Passed Failed Skipped
✅ astro-stable-node 134 0 26
✅ astro-stable-quickjs 134 0 26
✅ express-stable-node 134 0 26
✅ express-stable-quickjs 134 0 26
✅ fastify-stable-node 134 0 26
✅ fastify-stable-quickjs 134 0 26
✅ hono-stable-node 134 0 26
✅ hono-stable-quickjs 134 0 26
✅ nest-stable-node 134 0 26
✅ nest-stable-quickjs 134 0 26
✅ nextjs-turbopack-canary-node 141 0 19
✅ nextjs-turbopack-canary-quickjs 141 0 19
✅ nextjs-turbopack-stable-node 160 0 0
✅ nextjs-turbopack-stable-quickjs 160 0 0
✅ nextjs-webpack-canary-node 141 0 19
✅ nextjs-webpack-canary-quickjs 141 0 19
✅ nextjs-webpack-stable-node 160 0 0
✅ nextjs-webpack-stable-quickjs 160 0 0
✅ nitro-stable-node 134 0 26
✅ nitro-stable-quickjs 134 0 26
✅ nuxt-stable-node 134 0 26
✅ nuxt-stable-quickjs 134 0 26
✅ sveltekit-stable-node 153 0 7
✅ sveltekit-stable-quickjs 153 0 7
✅ tanstack-start-node 134 0 26
✅ tanstack-start-quickjs 134 0 26
✅ vite-stable-node 134 0 26
✅ vite-stable-quickjs 134 0 26

✅ 🐘 Local Postgres

App Passed Failed Skipped
✅ astro-stable-node 134 0 26
✅ astro-stable-quickjs 134 0 26
✅ express-stable-node 134 0 26
✅ express-stable-quickjs 134 0 26
✅ fastify-stable-node 134 0 26
✅ fastify-stable-quickjs 134 0 26
✅ hono-stable-node 134 0 26
✅ hono-stable-quickjs 134 0 26
✅ nest-stable-node 134 0 26
✅ nest-stable-quickjs 134 0 26
✅ nextjs-turbopack-canary-node 141 0 19
✅ nextjs-turbopack-canary-quickjs 141 0 19
✅ nextjs-turbopack-stable-node 160 0 0
✅ nextjs-turbopack-stable-quickjs 160 0 0
✅ nextjs-webpack-canary-node 141 0 19
✅ nextjs-webpack-canary-quickjs 141 0 19
✅ nextjs-webpack-stable-node 160 0 0
✅ nextjs-webpack-stable-quickjs 160 0 0
✅ nitro-stable-node 134 0 26
✅ nitro-stable-quickjs 134 0 26
✅ nuxt-stable-node 134 0 26
✅ nuxt-stable-quickjs 134 0 26
✅ sveltekit-stable-node 153 0 7
✅ sveltekit-stable-quickjs 153 0 7
✅ tanstack-start-node 134 0 26
✅ tanstack-start-quickjs 134 0 26
✅ vite-stable-node 134 0 26
✅ vite-stable-quickjs 134 0 26

✅ 🪟 Windows

App Passed Failed Skipped
✅ nextjs-turbopack-node 160 0 0
✅ nextjs-turbopack-quickjs 160 0 0

✅ 🌐 Cross-language Conformance

App Passed Failed Skipped
✅ python 9 0 132

✅ vercel-multi-region

App Passed Failed Skipped
✅ nextjs-turbopack 27 0 0

📋 View full workflow run

@github-actions

github-actions Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

📊 Workflow Benchmarks

commit 92aae4c · Thu, 20 Aug 2026 18:04:38 GMT · run logs

Backend: vercel · app: nextjs-turbopack

Metric Scenario Best (ms) P75 (ms) P90 (ms) P99 (ms) Samples
TTFS step 1240 (+20%) 🔻 1312 🔴 (+16%) 🔻 1338 🔴 (+14%) 1871 🔴 (+53%) 🔻 30
TTFS stream 469 (+163%) 🔻 1352 🔴 (+21%) 🔻 1405 🔴 (+25%) 🔻 1424 🔴 (+21%) 🔻 30
TTFS hook + stream 1526 (+207%) 🔻 1699 🔴 (+18%) 🔻 1735 🔴 (+18%) 🔻 1783 🔴 (+15%) 🔻 30
Fan-out TTFS Promise.all(100 steps) 517 (+30%) 🔻 1230 (+37%) 🔻 2157 (+23%) 🔻 2180 (+15%) 🔻 10
Fan-out TTLS Promise.all(100 steps) 4748 (-0.9%) 6874 (+11%) 6964 (+11%) 7243 (±0%) 10
STSO 1020 steps (inline) 122 (+1.7%) 245 (-0.8%) 288 (-4.0%) 503 (±0%) 1019
WO 1020 steps 229825 (-3.2%) 229825 (-3.2%) 229825 (-3.2%) 229825 (-3.2%) 1
CRTT first chunk (pooled) 88 (-4.3%) 143 (+8.3%) 209 (+38%) 🔻 606 (+267%) 🔻 28

Streams

Scenario CRTT 1st p75 p90 p99 CDV max iters
paced control (100/s, 60B) 109 (-11%) 126 (-13%) 198 (-25%) 851 (-23%) 151 (+2%) 10
size sweep (100/s, 160B-12KB) 115 (-11%) 159 (-28%) 403 (-23%) 970 (+25%) 226 (-17%) 10
replay gateway-gpt-5.4-nano-2000t (1x) 156 (+29%) 131 (-11%) 196 (-23%) 654 (-7%) 312 (-40%) 3
replay eve-gpt-5.6-sol-2000t (1x) 109 (-15%) 118 (-22%) 147 (-42%) 349 (-58%) 352 (-30%) 2
replay eve-gpt-5.6-sol-2000t (2x) 116 (-5%) 186 (-11%) 367 (+14%) 828 (-75%) 538 (-11%) 3
📈 STSO distribution vs main (inline / queue-hop histograms)

1020 steps (inline)

Cumulative STSO time: main 237191ms → this run 229562ms (Δ -7629ms, -3%)

  100-150 ms  █░░┃                      main  11  this  73   +62
  150-200 ms  ██████████████┃           main 293  this 301    +8
  200-250 ms  ████████████████████┃███  main 480  this 410   -70
  250-300 ms  ███████┃                  main 132  this 154   +22
  300-350 ms  █┃█                       main  53  this  47    -6
  350-400 ms  ┃                         main  26  this   9   -17
  400-450 ms  ┃                         main   5  this   8    +3
  450-500 ms  ┃                         main   7  this   5    -2
  500-550 ms  ┃                         main   4  this   4    +0
  550-600 ms  ┃                         main   3  this   1    -2
  600-650 ms  ┃                         main   1  this   3    +2
  650-700 ms  ┃                         main   2  this   0    -2
  700-750 ms  ┃                         main   1  this   2    +1
  800-850 ms  ┃                         main   1  this   0    -1
  850-900 ms  ┃                         main   0  this   1    +1
1250-1300 ms  ┃                         main   0  this   1    +1
📈 CRTT drill-down vs main (RTT distributions & profiles)
variant  RTT 1ms→5s+             avg         p50         p90         p99     n
control  ······██▁▁···  122.5 (-10%)   103 (-1%)  198 (-25%)  851 (-23%)  3000
sweep    ······██▃▂···   167.7 (+8%)   104 (-4%)  403 (-23%)  970 (+25%)  3000
gw 1x    ·····▁██▁▁···   119.8 (-9%)   104 (-5%)  196 (-23%)   654 (-7%)  5295
eve 1x   ·····▁█▆▁▁···  101.6 (-26%)   88 (-19%)  147 (-42%)  349 (-58%)  5186
eve 2x   ·····▁▅█▃▁···  156.9 (-20%)  119 (-15%)  367 (+14%)  828 (-75%)  7779

RTT over stream progress (avg per tenth of stream, bars scaled min→max):

control  ▃█▅▃▁▃▁▁▁▃  100–178ms
sweep    ▂▁▄▅█▆▅▆▅▅  126–204ms
gw 1x    █▄▁▂▄▃▂▁▂▁  97–185ms
eve 1x   ▅▃▄▁▂▂█▆▇▆  91–113ms
eve 2x   ▄▄▂▃▁▁▂█▃▄  116–246ms

RTT by chunk size (avg per log size bin, ~160B → ~12KB serialized, bars scaled min→max):

sweep  █▆▄▅▁▁▅  166–169ms

Delivery jitter over stream progress (avg positive CDV per tenth of stream, bars scaled min→max):

control  ▇▅▄▂▄▃▁▄▃█  30–43ms
sweep    ▁▄█▁▇▂▇▂▂▃  43–69ms
gw 1x    █▄▁▂▅▅▅▂▂▃  28–44ms
eve 1x   ▃▄▁▁▁▁█▂▃▆  20–29ms
eve 2x   ▆▄▁▅▃▁▂▇▄█  21–30ms
ℹ️ Metric definitions & methodology

Streams: first-chunk RTT (the stream-open path, before any buffering/backpressure), CRTT percentiles, and worst delivery stall (CDV max). Cells are medians across iterations; per-run values in the artifacts. No 🔴/🟢 marks until targets attach.

The collapsed STSO distribution section above buckets every step gap, split inline (same warm process — pure framework overhead) vs queue-hop (fresh process — dispatch, reinit, replay). = main, = this run, = fill.

The collapsed CRTT drill-down: per-variant RTT histograms (fixed log bins, · = empty) and mean RTT/positive-CDV profile lines over stream progress and chunk size. Histograms, avgs, and profiles merge exactly across runs; p50–p99 are percentile-of-percentiles. Per-index rows live in the artifacts.

Best/P75/P90/P99 deltas compare against the most recent benchmark run on main at the time of this run. 🔻 flags a delta worse than +15%, 💚 one better than −15%.

Metrics — TTFS: time to first step body (in-deployment start() → first step body) · Fan-out TTFS: fan-out time to first step (in-deployment start() → first of the parallel step bodies to complete) · Fan-out TTLS: fan-out time to last step (in-deployment start() → last of the parallel step bodies to complete, i.e. when the Promise.all resolves) · STSO: step-to-step overhead (gap between consecutive step bodies) · WO: workflow overhead (whole-run time outside step bodies, in-deployment anchored) · CRTT: chunk round-trip time (per-chunk write → read latency, one clock domain: deployment → stream backend → same deployment) · CDV: chunk delay variation / delivery jitter (inter-arrival gap minus inter-write gap per seq-adjacent pair; skew-free; the row is each run's MAX positive value, so one stall moves it)

Scenarios — step: one trivial no-op step, no stream; no hooks, so the run stays in turbo mode (in-process fast path) · stream: one streaming step; no hooks, so the run stays in turbo mode (in-process fast path) · hook + stream: registers a hook before one step, which exits turbo mode (dispatch path) · 1020 steps: 1020 trivial sequential steps; STSO is measured between consecutive steps in the given step ranges, and WO is the whole-run overhead outside step bodies · Promise.all(100 steps): 100 trivial no-op steps started together in a single Promise.all; Fan-out TTFS is the first of them to complete and Fan-out TTLS the last, both from the in-deployment clientStart, so their gap is the spread the runtime adds across the fan-out · paced control (100/s, 60B): the control: 300 tiny (~60B) deltas metronome-paced at 100/s — zero workload structure, so it reads the transport floor and flush cadence, and disambiguates transport-wide vs workload-specific when a replay row moves · size sweep (100/s, 160B-12KB): same pacing as the control with deltas padded in rotation across seven log-spaced sizes (~160B–12KB) — rotation decouples size from stream position, so it isolates whether chunk size causes latency · replay gateway-gpt-5.4-nano-2000t (1x): raw provider SSE cadence captured at the AI gateway boundary (gpt-5.4-nano, the most popular gateway model; per-token deltas p50 208B = the modal production chunk size), replayed exactly as measured — the typical customer's workload; its CDV is the typical customer's real delivery jitter · replay eve-gpt-5.6-sol-2000t (1x): a captured eve turn (gpt-5.6-sol, the most-used demanding eve model; ~2000 output tokens = production p50 turn length) replayed exactly as measured — eve's envelope protocol re-ships the cumulative message so sizes ramp 142B→13KB; the demanding outlier tenant's reality · replay eve-gpt-5.6-sol-2000t (2x): the same eve capture at 2x — the headroom/stress row; real fast-tier models emit the same chunk sizes at proportionally higher rate, so time compression is a faithful speed model · first chunk (pooled): every run's seq-0 RTT pooled across all stream scenarios — the first chunk precedes any workload differentiation, so pooling samples one shared stream-open path with exact percentiles

Replay cadences (semantic sha256) — eve-gpt-5.6-sol-2000t eaf22f5946e7c61f3c65c7006d550df180cfabd4e706254a09f22aec0cfb420d · gateway-gpt-5.4-nano-2000t 6f24ac518b6b83ff1d0e85a5fe78230db192716d66a7fc6b2fe022752001d041

🔴 marks a percentile over its target (within target is left unmarked). Targets (p75/p90/p99, ms) — TTFS 200/300/600

All timestamps are deployment-side; runs are triggered in-deployment, so the CI runner and api.vercel.com sit outside every measured window. TTFS = start() → first step body (includes dispatch + any cold start); Fan-out TTFS/TTLS = first/last step completion of one Promise.all from the same anchor (the gap is the runtime’s fan-out spread); STSO/WO between step bodies; CRTT inside the workflow (excludes the api.vercel.com read path).

Cold starts stay in the numbers (real bursty-workload latency, inflates P75+); Best is the warm floor.

@NathanColosimo NathanColosimo changed the title Resume partial replay event streams [world-vercel] Resume partial replay streams after validated events Aug 14, 2026
@NathanColosimo
NathanColosimo force-pushed the codex/replay-stream-recovery branch from e9e7488 to dbdc9a2 Compare August 14, 2026 03:56
@github-actions

github-actions Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Sim World

Simulated world deterministic testing for races. Traces

🟠 world-sim scenario book — 1 fail of 41 total

fence=per-spec

scenario outcome events virt replay violations
smoke-no-steps completed 3 0ms ok 0
smoke-one-step completed 6 0ms ok 0
hook-at-step-started completed 12 0ms ok 0
hook-at-step-completed completed 12 0ms ok 0
hook-at-hook-created completed 12 0ms ok 0
deadline-hook-wins completed 7 1.0h ok 0
deadline-expires completed 7 1.0h ok 0
long-sleep completed 11 30.0d ok 0
hook-never-arrives stalled 3 0ms skipped 0
step-retries-twice completed 10 2.0s ok 0
parallel-steps completed 9 0ms ok 0
hook-on-execution-state completed 12 0ms ok 0
peek-hook-before-branch completed 12 0ms ok 0
peek-hook-after-branch completed 12 0ms ok 0
peek-hook-at-registration completed 12 0ms ok 0
race-hook-before-probe completed 12 0ms ok 0
race-hook-after-probe completed 12 0ms ok 0
race-duplicate-delivery completed 13 0ms ok 0
attr-hook-before-step completed 11 0ms ok 0
attr-hook-after-step completed 11 0ms ok 0
attr-from-step-body completed 13 0ms ok 0
fork-hook-after-timeout completed 14 1.0m ok 0
fork-hook-before-timeout completed 14 1.0m ok 0
count-hook-after-timeout completed 17 1.0m ok 0
count-hook-before-timeout completed 20 1.0m ok 0
stale-read-step-count-fork completed 20 1.0m ok 0
stale-read-equal-step-counts completed 14 1.0m ok 0
step-vs-step-fork completed 12 0ms ok 0
step-vs-step-fork-fenced completed 12 0ms ok 0
fence-catches-benign-direction completed 12 5ms ok 0
in-flight-before-decision completed 17 1.0m ok 0
in-flight-before-decision-counted completed 17 1.0m ok 0
in-flight-after-decision completed 19 2.0m ok 0
stale-read-step-count-fork-fenced completed 20 1.0m ok 0
fork-hook-wins completed 13 1.0m ok 0
fork-timeout-wins completed 13 1.0m ok 0
unclaimed-payload-under-fork completed 17 1.0m ok 0
claimed-payload-under-fork completed 17 1.0m ok 0
writers-independent-step-bodies completed 12 0ms ok 0
writers-scripted-tempo completed 12 0ms ok 0
cancel-mid-step cancelled 7 0ms skipped 0

Full trace: world-sim.txt

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