Skip to content

fix(core): resolve child workflow cancellation on acknowledgment - #1850

Open
mfateev wants to merge 2 commits into
temporalio:mainfrom
mfateev:codex/fix-child-wait-cancellation-requested
Open

mfateev wants to merge 2 commits into
temporalio:mainfrom
mfateev:codex/fix-child-wait-cancellation-requested

Conversation

@mfateev

@mfateev mfateev commented Nov 26, 2026

Copy link
Copy Markdown
Member

What was changed

Route the server acknowledgment of a child Workflow cancellation request back to the child state machine. WaitCancellationRequested resolves when that acknowledgment arrives. If the child start is still pending, Core resolves the start as canceled. Explicit FSM transitions ignore acknowledgments after resolution and prevent duplicate results.

Record the behavior with a Core replay flag when the Workflow Task issues the cancel command. This preserves replay for cancellation requests already recorded by older workers.

Why?

Core previously waited for the child to finish even after the server confirmed delivery. A child that handles cancellation and keeps running could leave the parent waiting.

Checklist

  • Added regression coverage for live execution, replay, worker upgrades, and acknowledgment before the child start event.
  • 697 Core unit tests and 29 targeted integration tests passed.
  • cargo lint, nightly formatting checks, and cargo changelog-check passed.

@mfateev
mfateev requested a review from a team as a code owner November 26, 2026 03:46

This branch has not been deployed

No deployments
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