Skip to content

Remove event_loop fixture #1106

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
May 5, 2025

Conversation

seifertm
Copy link
Contributor

@seifertm seifertm commented May 2, 2025

This PR removes the deprecated event_loop fixture along with the associated warnings, such as the unclosed loop warning, the warning about requesting event_loop in async fixtures and tests, and the warning about multiple loops being requested in the same test.

This patch follows up the deprecation of the event_loop fixture in v0.22/v0.23 and represents a major cleanup of the pytest-asyncio code base.

@seifertm seifertm added this to the v1.0 milestone May 2, 2025
@seifertm seifertm self-assigned this May 2, 2025
@codecov-commenter
Copy link

codecov-commenter commented May 2, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.60%. Comparing base (22b4080) to head (44162c4).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1106      +/-   ##
==========================================
- Coverage   90.84%   90.60%   -0.25%     
==========================================
  Files           2        2              
  Lines         579      500      -79     
  Branches       77       64      -13     
==========================================
- Hits          526      453      -73     
+ Misses         32       30       -2     
+ Partials       21       17       -4     

☔ 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.

@seifertm seifertm marked this pull request as ready for review May 2, 2025 11:12
@seifertm seifertm requested review from asvetlov and Tinche as code owners May 2, 2025 11:12
@seifertm seifertm added this pull request to the merge queue May 5, 2025
@seifertm seifertm removed this pull request from the merge queue due to a manual request May 5, 2025
@seifertm seifertm force-pushed the remove-event-loop-fixture2 branch from b2280dc to 44162c4 Compare May 5, 2025 04:19
@seifertm seifertm enabled auto-merge May 5, 2025 04:19
@seifertm seifertm added this pull request to the merge queue May 5, 2025
Merged via the queue into pytest-dev:main with commit 959c9f0 May 5, 2025
16 of 17 checks passed
@seifertm seifertm deleted the remove-event-loop-fixture2 branch May 5, 2025 04:25
@seifertm seifertm restored the remove-event-loop-fixture2 branch May 5, 2025 04:26
@seifertm seifertm mentioned this pull request May 5, 2025
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.

2 participants