Skip to content

Parallel isolation guard: list the Hub download tests poll deadlines as benign timing - #16526

Merged
danielhanchen merged 1 commit into
mainfrom
dh/hf-download-poll-deadlines-benign
Nov 3, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
dh/hf-download-poll-deadlines-benign

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

Summary

workflow-trigger lint is red on main since #16422 (1a951a93d6). Its "Workflow guard suites" step fails on unrelated PRs. In the last hour that was the staging runs for #16423, #16182 and #16523:

tests/studio/test_backend_ci_parallel_isolation.py::test_every_tight_elapsed_bound_is_isolated
AssertionError: these backend tests compare clock-derived values and still run under -n 4 ...:
{'test_hf_download_fallback_and_kill.py': ['...:32 one duration against another'],
 'test_hf_download_reclaim_race.py': ['...:113 one duration against another'],
 'test_hf_download_ref_concurrency.py': ['...:72 one duration against another']}

All three sites are the same poll loop, which waits for a child process to touch a ready file:

deadline = time.monotonic() + 20   # 10 in test_hf_download_ref_concurrency.py
while not (tmp_path / "ready").exists():
    assert child.poll() is None, child.communicate()
    assert time.monotonic() < deadline, "worker did not reach the transfer barrier"
    time.sleep(0.01)

Being descheduled under -n 4 only delays a poll; it cannot make the condition false. The guard casts a deliberately wide net, and its message names this exact case: a poll deadline goes in BENIGN_TIMING as (file, enclosing function) with a reason. The tests and #16422's download logic are fine; those entries were just never added.

Change

tests/studio/test_backend_ci_parallel_isolation.py: three BENIGN_TIMING entries under one reason comment. Each names the function that holds the loop:

  • _wait_for_transfer
  • test_gguf_reclaim_preserves_publication_and_active_peer
  • test_peer_completion_survives_an_older_process

I checked each of those functions: its only uses of time. are this deadline, the comparison and the sleep, so the entries hide no other timing check.

Testing

  • tests/studio/test_backend_ci_parallel_isolation.py:
    • main: test_every_tight_elapsed_bound_is_isolated fails with the error above;
    • this branch: 43 passed.
  • No product or workflow file changes.

@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-03T06:24:21.981315Z adb5c9d Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep it up!

Reviewed commit: adb5c9d91a

ℹ️ 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".

@danielhanchen
danielhanchen merged commit de02164 into main Nov 3, 2026
@danielhanchen
danielhanchen deleted the dh/hf-download-poll-deadlines-benign branch November 3, 2026 06:24
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