Skip to content

Add missing flag 4 behavior changes to the changelog - #2193

Merged
VegetarianOrc merged 2 commits into
amazzeo/workflow-wait-condition-cancellationfrom
alexmazzeo/sdk-605-flag-4-add-the-missing-behavior-changes
Dec 3, 2026
Merged

VegetarianOrc merged 2 commits into
amazzeo/workflow-wait-condition-cancellationfrom
alexmazzeo/sdk-605-flag-4-add-the-missing-behavior-changes

Conversation

@VegetarianOrc

@VegetarianOrc VegetarianOrc commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

What was changed

The flag 4 changelog fragment (changelog/added/tumbling-job-basket.md) now lists the effects that users can see:

  • A workflow.wait_condition() call that is shielded or in another task, such as a signal or update handler, can finish after cancellation.
  • A signal to an external or child workflow that completes in the same workflow task as a cancellation raises asyncio.CancelledError.
  • A handle cancel in the workflow task that delivers the result can take priority over the result.
  • workflow.all_handlers_finished() can return False more often in the workflow task where a signal handler finishes.
  • Signal and update handlers do not run if applying another job in the same workflow task fails the workflow.
  • On Python 3.11, workflow.wait_condition() timeouts round to the nearest millisecond.

The flag 4 comment in temporalio/_workflow_context.py now has a reminder: when a release enables flag 4 by default, its changelog must name the minimum SDK version that replays flag 4 histories.

Why?

The fragment left out these effects. An older SDK can replay a flag 4 history with different results and no nondeterminism error, so the release that enables flag 4 must state the minimum version.

Checklist

  1. Refs SDK-605. Stacked on Add activation batching flag with task-local cancellation #2149.

  2. How was this tested: changelog-tool check passed.

  3. Any docs updates needed? This PR is the changelog update.

🤖 Generated with Claude Code

@VegetarianOrc
VegetarianOrc added this pull request to stack #2196 December 2, 2026 23:39
@VegetarianOrc VegetarianOrc changed the title alexmazzeo/sdk 605 flag 4 add the missing behavior changes Add missing flag 4 behavior changes to the changelog Dec 2, 2026
@VegetarianOrc
VegetarianOrc force-pushed the alexmazzeo/sdk-605-flag-4-add-the-missing-behavior-changes branch 2 times, most recently from 42b891a to a2d988d Compare December 3, 2026 00:13
Base automatically changed from alexmazzeo/sdk-604-flag-4-send-a-cancel-request-to-a-child to main December 3, 2026 00:17
@VegetarianOrc
VegetarianOrc removed this pull request from stack #2196 December 3, 2026 00:18
@VegetarianOrc
VegetarianOrc changed the base branch from main to amazzeo/workflow-wait-condition-cancellation December 3, 2026 00:18
@VegetarianOrc
VegetarianOrc added this pull request to stack #2197 December 3, 2026 00:18
VegetarianOrc and others added 2 commits December 2, 2026 16:20
List the flag 4 effects that users can see but the fragment left out:
external and child signals, handle cancel after a result,
all_handlers_finished(), job failures during apply, Python 3.11
timeout rounding, and handler waits after cancellation. Also add a
reminder to name the minimum replay version when flag 4 becomes a
default.

Refs SDK-605.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Address review findings on the flag 4 fragment:
- Split the first entry into three entries.
- Name the exact call or handler that each entry affects.
- Add update handlers to the job failure entry.
- Name asyncio.CancelledError.
- Follow the existing flag reminder form in the TODO.

Refs SDK-605.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@VegetarianOrc
VegetarianOrc force-pushed the alexmazzeo/sdk-605-flag-4-add-the-missing-behavior-changes branch from a2d988d to 282c446 Compare December 3, 2026 00:22
@VegetarianOrc
VegetarianOrc merged commit 282c446 into main Dec 3, 2026
18 of 19 checks passed
@VegetarianOrc
VegetarianOrc deleted the alexmazzeo/sdk-605-flag-4-add-the-missing-behavior-changes branch December 3, 2026 00:37
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