Skip to content

chore: update pytest-asyncio uvloop configuration#251

Merged
toby-coleman merged 7 commits intomainfrom
copilot/update-usage-of-uvloop
Apr 23, 2026
Merged

chore: update pytest-asyncio uvloop configuration#251
toby-coleman merged 7 commits intomainfrom
copilot/update-usage-of-uvloop

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 15, 2026

Summary

Update the test suite’s uvloop integration to align with pytest-asyncio’s loop-factory direction ahead of Python 3.14 policy deprecations. The shared pytest configuration now uses the hook-based uvloop setup only, matching the repository’s pytest-asyncio>=1.0,<2 requirement.

Changes

  • pytest-asyncio loop factory hook

    • Keep pytest_asyncio_loop_factories(...) in /home/runner/work/plugboard/plugboard/tests/conftest.py
    • Configure uvloop via uvloop.new_event_loop
  • Remove obsolete compatibility fallback

    • Drop the conditional event_loop_policy fallback for older pytest-asyncio releases
    • Simplify the hook implementation now that the project locks to pytest-asyncio 1.x
  • Focused coverage

    • Keep /home/runner/work/plugboard/plugboard/tests/unit/test_conftest.py
    • Update it to validate only the supported hook-based uvloop configuration path
  • Branch maintenance

    • Merge origin/main into this branch and resolve the resulting conflict in /home/runner/work/plugboard/plugboard/tests/conftest.py
  • Validation

    • Ran make lint
    • Ran make build
    • Ran uv run pytest -rs tests/unit/test_conftest.py tests/integration/test_component_event_handlers.py

Copilot AI linked an issue Apr 15, 2026 that may be closed by this pull request
Copilot AI and others added 4 commits April 15, 2026 21:02
Agent-Logs-Url: https://github.com/plugboard-dev/plugboard/sessions/97ae65cc-0c75-4da6-83fa-22fbc21aa4d6

Co-authored-by: toby-coleman <13170610+toby-coleman@users.noreply.github.com>
Agent-Logs-Url: https://github.com/plugboard-dev/plugboard/sessions/97ae65cc-0c75-4da6-83fa-22fbc21aa4d6

Co-authored-by: toby-coleman <13170610+toby-coleman@users.noreply.github.com>
Agent-Logs-Url: https://github.com/plugboard-dev/plugboard/sessions/97ae65cc-0c75-4da6-83fa-22fbc21aa4d6

Co-authored-by: toby-coleman <13170610+toby-coleman@users.noreply.github.com>
Agent-Logs-Url: https://github.com/plugboard-dev/plugboard/sessions/97ae65cc-0c75-4da6-83fa-22fbc21aa4d6

Co-authored-by: toby-coleman <13170610+toby-coleman@users.noreply.github.com>
Copilot AI changed the title [WIP] Update usage of uvloop for pytest-asyncio chore: update pytest-asyncio uvloop configuration Apr 15, 2026
Copilot AI requested a review from toby-coleman April 15, 2026 21:09
@toby-coleman
Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Co-authored-by: toby-coleman <13170610+toby-coleman@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Apr 22, 2026

@copilot resolve the merge conflicts in this pull request

Resolved in 25612da.

@toby-coleman toby-coleman marked this pull request as ready for review April 22, 2026 13:47
Comment thread tests/conftest.py Outdated
Comment thread tests/conftest.py Outdated
Agent-Logs-Url: https://github.com/plugboard-dev/plugboard/sessions/1dcc6e9b-2a3e-46e1-9493-f1dd0572e763

Co-authored-by: toby-coleman <13170610+toby-coleman@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Apr 23, 2026

Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • releases.astral.sh
    • Triggering command: /home/REDACTED/.local/bin/uv uv venv .venv --python python3.13 (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

@github-actions
Copy link
Copy Markdown

Benchmark comparison for 7a2c291b (base) vs 8f536ba0 (PR)


------------------------------------------------------------------------------------------------------------------ benchmark: 2 tests -----------------------------------------------------------------------------------------------------------------
Name (time in ms)                                                                         Min                 Max                Mean            StdDev              Median               IQR            Outliers     OPS            Rounds  Iterations
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
test_benchmark_process_run (main/.benchmarks/Linux-CPython-3.14-64bit/0001_base)     461.0892 (1.0)      468.2611 (1.0)      464.5892 (1.0)      3.3089 (1.0)      464.8596 (1.0)      6.2795 (1.06)          2;0  2.1524 (1.0)           5           1
test_benchmark_process_run (pr/.benchmarks/Linux-CPython-3.14-64bit/0001_pr)         513.4655 (1.11)     523.5000 (1.12)     518.0462 (1.12)     3.9177 (1.18)     517.6257 (1.11)     5.9271 (1.0)           2;0  1.9303 (0.90)          5           1
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Legend:
  Outliers: 1 Standard Deviation from Mean; 1.5 IQR (InterQuartile Range) from 1st Quartile and 3rd Quartile.
  OPS: Operations Per Second, computed as 1 / Mean

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@toby-coleman toby-coleman merged commit 07750b3 into main Apr 23, 2026
44 of 45 checks passed
@toby-coleman toby-coleman deleted the copilot/update-usage-of-uvloop branch April 23, 2026 19:09
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.

chore: Update usage of uvloop

2 participants