Repository navigation
Add wait_for_reverification to FixesClient and AsyncFixesClient - #150
Open
05sanjaykumar wants to merge 2 commits into
Open
05sanjaykumar wants to merge 2 commits into
05sanjaykumar wants to merge 2 commits into
Conversation
05sanjaykumar
force-pushed
the
feat/wait-for-reverification
branch
from
December 2, 2026 13:28
c219dbe to
3acedbe
Compare
This branch has not been deployed
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.
Problem
FixesClientandAsyncFixesClientexposerequest_reverification()andget_reverification(request_id), but callers have no built-in helper to wait for a reverification request to reach a terminal state.Solution
wait_for_reverification(request_id, *, timeout=300, poll_interval=5.0, organization_id=None)to bothFixesClientandAsyncFixesClientinproofline/fixes.py._transport.review_wait_budget(timeout)and exponential backoff (poll_intervaldoubling up tomax(60.0, poll_interval)), returning immediately on terminal statuses orisError=True, and raisingTimeoutErrorif the deadline expires while still active (PENDING,QUEUED,RUNNING,IN_PROGRESS)._validate_wait_argsforrequest_id,timeout, andpoll_interval.Verification
tests/test_fixes_wait.pyusingtests.http_server.Server.python3 scripts/check.py(ruff check & format, mypy across 232 files, 247/247 tests passing, wheel & sdist smoke installs).Proofline Review
Installed Proofline on
05sanjaykumar/sdk-python(fork PR #1). Proofline flagged two issues:60.0swould speed up polling when a caller passedpoll_interval > 60s— updated the cap tomax(60.0, poll_interval)and added apoll_interval=90.0regression test.timeout=0rather than a positive timeout with an advancing clock — updated to usetimeout=5.0with a fake monotonic clock advancing during the status call and assertedasync_sleepis not called.