Skip to content

test: make parent cancellation tests deterministic - #4193

Merged
seratch merged 1 commit into
mainfrom
test/deterministic-parent-cancellation-tests
Aug 5, 2026
Merged

test: make parent cancellation tests deterministic#4193
seratch merged 1 commit into
mainfrom
test/deterministic-parent-cancellation-tests

Conversation

@seratch

@seratch seratch commented Aug 5, 2026

Copy link
Copy Markdown
Member

This pull request fixes two scheduler-sensitive parent-cancellation tests originally proposed in #4166, a follow-up to #4165.

Maintainer review confirmed the underlying flakiness, but the latest #4166 callback rendezvous could still complete on the wrong background task. A focused trace also confirmed that the current parent-cancellation path completes through the detached outer tool task and its wrapped UserError.

This maintainer-side takeover starts from current main, preserves the settlement-pipeline assertion from the original contribution, and waits for the exact detached task and exception before checking that no loop-level error is reported. No runtime behavior changes.

Replace scheduler-sensitive cancellation assertions with state-driven synchronization and exact background callback observation.

Co-authored-by: Shaurya Singh <sshaurya914@gmail.com>
@seratch seratch added this to the 0.19.x milestone Aug 5, 2026
@seratch seratch added the project label Aug 5, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 90a15db97e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread tests/test_run_step_execution.py
@seratch
seratch merged commit e064ab6 into main Aug 5, 2026
9 checks passed
@seratch
seratch deleted the test/deterministic-parent-cancellation-tests branch August 5, 2026 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant