Outcome
The managed pytest configuration exposes no closed option for pytest-asyncio settings (notably asyncio_mode), and the managed [tool.pytest.ini_options] at the root shadows a subproject's own pyproject configuration. A repository adopting python-tooling over a subproject with async tests fails its gate until tests are edited or an undocumented mechanism is found.
Evidence
- Fresh adoption, project-standards 5.26.0 (
v5.26.0), Linux, Python 3.14.7.
- python-tooling 1.16 with
pytest.test_paths = ["subproj/tests"]; the subproject's own pyproject.toml sets asyncio_mode = "auto" under its own [tool.pytest.ini_options].
- Under the root-managed config, pytest's rootdir is the repository root, so the subproject ini is not read; async tests fail with:
Failed: async def functions are not natively supported
The closed pytest options (fail_under, markers, coverage_exclude_also, test_paths) cannot express asyncio_mode, and [tool.pytest.ini_options] cannot be declared twice.
Expected behavior
Either a closed option to pass through pytest ini values (e.g. ini = { asyncio_mode = "auto" }), or adoption guidance stating that async tests must carry explicit pytest.mark.asyncio markers when adopted under a root-managed configuration, plus that the async plugin must be added via additional_dev_dependencies.
Workaround used
Added module-level pytestmark = pytest.mark.asyncio to the affected test modules (compatible with both asyncio modes) and pytest-asyncio through additional_dev_dependencies.
Blocks progress: no (workaround found).
Outcome
The managed pytest configuration exposes no closed option for pytest-asyncio settings (notably
asyncio_mode), and the managed[tool.pytest.ini_options]at the root shadows a subproject's own pyproject configuration. A repository adopting python-tooling over a subproject with async tests fails its gate until tests are edited or an undocumented mechanism is found.Evidence
v5.26.0), Linux, Python 3.14.7.pytest.test_paths = ["subproj/tests"]; the subproject's ownpyproject.tomlsetsasyncio_mode = "auto"under its own[tool.pytest.ini_options].The closed pytest options (
fail_under,markers,coverage_exclude_also,test_paths) cannot expressasyncio_mode, and[tool.pytest.ini_options]cannot be declared twice.Expected behavior
Either a closed option to pass through pytest ini values (e.g.
ini = { asyncio_mode = "auto" }), or adoption guidance stating that async tests must carry explicitpytest.mark.asynciomarkers when adopted under a root-managed configuration, plus that the async plugin must be added viaadditional_dev_dependencies.Workaround used
Added module-level
pytestmark = pytest.mark.asyncioto the affected test modules (compatible with both asyncio modes) andpytest-asynciothroughadditional_dev_dependencies.Blocks progress: no (workaround found).