Skip to content

Update pytest-asyncio to 1.4.0 - #1547

Open
Jakuje wants to merge 1 commit into
abhinavsingh:developfrom
Jakuje:pytest-asyncio
Open

Jakuje wants to merge 1 commit into
abhinavsingh:developfrom
Jakuje:pytest-asyncio

Conversation

@Jakuje

@Jakuje Jakuje commented Oct 8, 2026

Copy link
Copy Markdown

No description provided.

@pyba-chronographer pyba-chronographer Bot added the bot:chronographer:provided Used by chronographer to mark a PR as CHANGELOG provider label Oct 8, 2026
Comment thread tests/conftest.py Resolved
Comment thread tests/conftest.py
import pytest


@pytest.fixture(autouse=True) # type: ignore[misc]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what was the violation?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was also taken from existing tests, but the problem still exists:

tests/conftest.py:16: error: Untyped decorator makes function "_event_loop_before_mocks" untyped  [misc]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, then it makes sense to leave a comment explaining when it's fine to drop the ignore.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAIK the unused ignore should report its own warning.

@webknjaz webknjaz Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But this means that I order to learn what the problem was, one would have to

  1. Clone the repo
  2. Set up the dev env
  3. Remove the ignore
  4. Run MyPy
  5. Contemplate on the reasons for not fixing the underlying problem
  6. Recover the type ignore
  7. Repeat for each unexplained suppression

Instead, with a code comment, a reader could

  1. Read it
  2. Understand the motivation

Wouldn't it be nicer to optimize for the reader?

Comment thread tests/conftest.py Resolved
Comment thread docs/changelog-fragments.d/1547.misc.md Resolved
Comment thread docs/changelog-fragments.d/1547.misc.md Resolved
This requires to initialize the `asyncio` event loop before other
fixtures to keep some of the tests working.

Signed-off-by: Jakub Jelen <jjelen@redhat.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot:chronographer:provided Used by chronographer to mark a PR as CHANGELOG provider

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants