Skip to content

Use pytest-beartype-tests plugin#3116

Merged
adamtheturtle merged 2 commits intomainfrom
use-pytest-beartype-tests-plugin
Apr 19, 2026
Merged

Use pytest-beartype-tests plugin#3116
adamtheturtle merged 2 commits intomainfrom
use-pytest-beartype-tests-plugin

Conversation

@adamtheturtle
Copy link
Copy Markdown
Member

@adamtheturtle adamtheturtle commented Apr 19, 2026

This PR adds the pytest-beartype-tests dev dependency and removes redundant pytest_collection_modifyitems wiring from conftest where it duplicated the plugin.

The dependency is pinned to git bc81d99 via [tool.uv.sources] until a PyPI release includes the Sybil-safe plugin fix.

Made with Cursor


Note

Medium Risk
Low impact on production code, but it changes the test collection/runtime behavior and introduces a git-pinned pytest plugin dependency, which could affect CI stability and reproducibility.

Overview
Shifts beartype enforcement for tests from a custom pytest_collection_modifyitems hook in conftest.py to the external pytest-beartype-tests plugin (removing the redundant collection-time wrapping).

Adds pytest-beartype-tests to dev dependencies and configures uv to install it from a specific git revision (bc81d99), plus introduces an empty [dependency-groups]/dev group entry in pyproject.toml.

Reviewed by Cursor Bugbot for commit 43b5b51. Bugbot is set up for automated code reviews on this repo. Configure here.

Replace manual pytest_collection_modifyitems hooks with the
https://github.com/adamtheturtle/pytest-beartype-tests dev dependency.

Made-with: Cursor
Use git+https dependency until the next PyPI release includes
adamtheturtle/pytest-beartype-tests@bc81d99.
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 43b5b51. Configure here.

Comment thread pyproject.toml
urls.Source = "https://github.com/VWS-Python/vws-python-mock"

[dependency-groups]
dev = []
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Empty dependency-groups dev shadows optional-dependencies dev

Low Severity

The newly added [dependency-groups] section with dev = [] is empty and serves no apparent purpose. All CI workflows use uv run --extra=dev, which references optional-dependencies.dev. This empty group creates a trap: a future developer running uv sync --group dev would get zero dependencies installed instead of the full dev set. The PR description doesn't mention this addition, suggesting it may be unintentional.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 43b5b51. Configure here.

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