Repository navigation
Pin the condition-wait reopen rule after a timeout and in selections - #250
Merged
Merged
Conversation
A separate wait after a timed-out one measures from its own open (approve gives late, a wrong signal gives 31, an equal timeout gives 271), and a condition inside ctx.select is not re-sent by a wrong signal, so the remaining-time rule does not apply to it. Requested in General's sdk-php#271 cross-check of #246. Refs #245. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Member
Author
|
General interim review (Security unavailable; General didn't write this PR): exact head
Merge only this SHA. |
|
Member
Author
|
Merged at General's verification of refreshed head
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



This answers General's two questions from the sdk-php#271 cross-check of #246 (merged as
1310272d), as tests onmain. It changes tests only.A separate wait after a timed-out wait measures from its own open.
GraceAfterTimeoutwaits 300 s, then after the timeout opens a 60 s grace wait with the same key and predicate. Using General's vectors, with the grace wait opened at 00:05:00 and a signal at 00:05:29:"late";Python finds a reopen's first open by predicate replay. A
condition_timeoutresolution ends the first yield before any reopen is linked, so the grace wait is a new logical wait.Condition waits in parallel groups. Ordinary parallel lists already refuse
WaitCondition(test_ordinary_parallel_group_rejects_wait_condition_locally). A condition insidectx.selectis never re-sent while it is open: a wrong signal produces no command, so its original timer keeps its deadline. The new test pins that. No issue is needed, because the remaining-time rule has no reopen to apply to there.Local:
ruffis clean andtests/test_wait_condition.pygives 54 passed against this branch's source.🤖 Generated with Claude Code