Skip to content

test: widen QM follow-up window in info_asking_default test#1765

Merged
bdraco merged 1 commit into
masterfrom
test/widen-qm-followup-timeout
May 20, 2026
Merged

test: widen QM follow-up window in info_asking_default test#1765
bdraco merged 1 commit into
masterfrom
test/widen-qm-followup-timeout

Conversation

@bdraco

@bdraco bdraco commented May 20, 2026

Copy link
Copy Markdown
Member

Summary

test_info_asking_default_is_asking_qm_questions_after_the_first_qu flakes on macOS-latest skip_cython; the 50ms QUICK_REQUEST_TIMEOUT_MS budget leaves about 35ms of headroom for the QM follow-up that fires at roughly 11 to 15ms after the QU, and macOS asyncio short-sleep quantization occasionally pushes the wake past the 50ms cap so the loop returns before the QM is sent and second_outgoing stays None.

Details

  • The test asserts only that the second outgoing query is QM, the exact wall-clock budget is not part of the contract.
  • Bump this test's timeout to 300ms; that absorbs macOS scheduling jitter without changing the shared QUICK_REQUEST_TIMEOUT_MS constant that other tests rely on.
  • Drop the now unused QUICK_REQUEST_TIMEOUT_MS import from tests/test_asyncio.py.

Observed in run 26185961578 on PR #1764; the failure is timing only and not related to that PR's contents.

Test plan

  • SKIP_CYTHON=1 poetry run pytest tests/test_asyncio.py::test_info_asking_default_is_asking_qm_questions_after_the_first_qu
  • SKIP_CYTHON=1 poetry run pytest tests/test_asyncio.py
  • pre-commit clean on the modified file

The 50ms QUICK_REQUEST_TIMEOUT_MS budget for this test left ~35ms of
headroom for the QM query that fires ~11-15ms after the QU; on
macOS-latest skip_cython runs the asyncio short-sleep quantization
occasionally pushed the wake past the 50ms cap, so the loop returned
before the QM was sent and second_outgoing stayed None.

The test only asserts that the second outgoing query is QM, the exact
wall-clock budget is not part of the contract, so bump this test's
timeout to 300ms; that absorbs macOS scheduling jitter without leaning
on the shared QUICK_REQUEST_TIMEOUT_MS constant other tests rely on.
@codspeed-hq

codspeed-hq Bot commented May 20, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 14 untouched benchmarks


Comparing test/widen-qm-followup-timeout (e3eedba) with master (90a5a39)

Open in CodSpeed

@codecov

codecov Bot commented May 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.77%. Comparing base (90a5a39) to head (e3eedba).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1765   +/-   ##
=======================================
  Coverage   99.77%   99.77%           
=======================================
  Files          33       33           
  Lines        3509     3509           
  Branches      493      493           
=======================================
  Hits         3501     3501           
  Misses          5        5           
  Partials        3        3           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bdraco bdraco marked this pull request as ready for review May 20, 2026 20:03
@bdraco bdraco merged commit 4ffba87 into master May 20, 2026
34 checks passed
@bdraco bdraco deleted the test/widen-qm-followup-timeout branch May 20, 2026 20:03
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