Skip to content

Rework setuptools-scm configuration #1192

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 9 commits into from
Aug 17, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,3 @@ target/

# pyenv
.python-version


# generated by setuptools_scm
pytest_asyncio/_version.py
8 changes: 2 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
[build-system]
build-backend = "setuptools.build_meta"
requires = [
"setuptools>=77",
"setuptools-scm[toml]>=6.2",
"setuptools==80.9",
"setuptools-scm==9.2",
]

[project]
Expand Down Expand Up @@ -67,7 +67,6 @@ packages = [
include-package-data = true

[tool.setuptools_scm]
write_to = "pytest_asyncio/_version.py"
local_scheme = "no-local-version"

[tool.ruff]
Expand Down Expand Up @@ -138,9 +137,6 @@ source = [
]
branch = true
data_file = "coverage/coverage"
omit = [
"*/_version.py",
]
parallel = true

[tool.coverage.report]
Expand Down
5 changes: 4 additions & 1 deletion pytest_asyncio/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

from __future__ import annotations

from ._version import version as __version__ # noqa: F401
from importlib.metadata import version

from .plugin import fixture, is_async_test

__version__ = version(__name__)

__all__ = ("fixture", "is_async_test")
18 changes: 0 additions & 18 deletions setup.cfg

This file was deleted.

5 changes: 5 additions & 0 deletions tests/test_package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import pytest_asyncio


def test_package_exposes_version():
assert pytest_asyncio.__version__
Loading