try/finally around steps: replay consumes the finally step while step_created still belongs to the try step
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 48/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- typescript
- Área
- backend
Línea de trabajo
Start from the divergence error text in the replay engine — search the repo for the message fragment 'belongs to' / 'current step consumer is' to find where a step_created event is matched against the current step consumer, then trace how try/catch/finally constructs push the finally step onto the consumer stack while an awaited step inside try is still pending. Check the scheduler's suspension/resume path for steps awaiting completion, and reproduce with a workflow shaped like the one in the issue (step in try, step in finally, a step_created written for the try step). Done means replay keeps consuming the try step's events until step_completed/step_failed and only then runs the finally step, verified by a replay test that previously produced REPLAY_DIVERGENCE / CORRUPTED_EVENT_LOG.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What happened
A production workflow on Vercel ([email protected], Next.js, world-vercel) failed with CORRUPTED_EVENT_LOG after the automatic recovery budget. The divergent event is a step_created for a step inside try, consumed on replay by the step in finally.
Error: Workflow replay diverged 4 times after 3 recovery replays; latest divergent event was evnt_01M47BPBHPG5TAVN1PKD1SNVR6.
Last divergence: Replay divergence: step event step_created for step_01M47BM6V9W4JTDTY2TMM2HR92 belongs to "step//./src/cms-api/generation/durable/pipelineSteps//generateSectionImagesStep", but the current step consumer is "step//./src/cms-api/generation/durable/pipelineSteps//settleBuiltSectionStep"
errorName: CorruptedEventLogError
errorCode: CORRUPTED_EVENT_LOG
Recovery warnings immediately before that, same run, same event, divergenceCount: 3, maxRecoveryReplays: 3, errorCode: REPLAY_DIVERGENCE.
- Corrupted run:
wrun_01M47BM6HBPPBHY286J10MYGM6 - Deployment:
dpl_EbxN86u6K6HSjm5QDbQ8YxARbJki - When: 2026-10-06T01:01:52Z (divergence) → 2026-10-06T01:01:53Z (corrupted)
- Package:
[email protected](latest 4.x at the time of writing is 4.8.12; 5.0.1 is current)
The parent run kept polling a status step for 3 hours and then timed out. The section run itself never reached step_completed for generateSectionImagesStep.
Workflow shape
"use workflow" with three "use step" calls. reusesShared is a workflow argument, stable across replays. On this run it was false, so the images step was reached and its step_created was written.
export async function sectionWorkflow(input: { reusesShared: boolean }) {
"use workflow"
try {
await writeSectionHtmlStep(input)
if (input.reusesShared) return
await generateSectionImagesStep(input)
} catch (error) {
await recordSectionFailureStep(input)
throw error
} finally {
await settleBuiltSectionStep(input)
}
}
writeSectionHtmlStep had already completed. The next recorded event is step_created for generateSectionImagesStep. Replay then tried to run settleBuiltSectionStep from finally instead of consuming that images step.
Expected
try / catch / finally around steps is documented as normal orchestration (including the child-workflow cookbook, which resumes a hook from finally). Suspending inside try on an in-flight step should not run finally until that step settles. Replay should keep consuming generateSectionImagesStep until step_completed or step_failed, and only then run settleBuiltSectionStep.
Actual
One invocation writes step_created for the images step. The next invocation's step consumer is the finally step. Three recovery replays hit the same event, then the run is marked corrupted. The divergence is not catchable inside the workflow, so the catch step never records the failure either.
https://useworkflow.dev/err/replay-divergence asks for the run id when recovery does not clear CORRUPTED_EVENT_LOG. Happy to pull more of the event log if that helps.
- Lenguaje dominante
- TypeScript
- Estrellas
- 2.5k
- Forks
- 401
- Merge medio
- 1 d 21 h
- PR fusionados (30 d)
- 201
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Sin guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de vercel/workflow
-
getPortLazy re-runs OS port discovery on every call when it finds no portPosiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
Los mantenedores suelen responder en 1 día
-
node-module-esbuild-plugin: getImportedIdentifier only checks the first named import when locating a violationPosiblemente ocupada @div-cowboy la tomó hace 5 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
vercel/workflow#5057 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
code-transform.mdx §ID Generation omits the package-shipped `name@version` ID formPosiblemente ocupada @Mohith26 la tomó hace 113 días. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100
Los mantenedores suelen responder en 1 día
Todos los issues de vercel/workflow
Issues similares
-
Dificultad 1/5 1-3 horas Aptitud para principiantes 87/100
Los mantenedores suelen responder en 1 día
-
🛠️ dette technique
Dificultad 2/5 1-3 horas Aptitud para principiantes 61/100
betagouv/mon-entreprise#4752 · 1 comentario ·
Los mantenedores suelen responder en 5 días
-
type: bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
franciscoBSalgueiro/en-croissant#1111 ·
Los mantenedores suelen responder en 2 días
-
area/providers type/feature version/v2
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
anomalyco/opencode#64845 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día