diff --git a/pytest_asyncio-1.2.0.tar.gz b/pytest_asyncio-1.2.0.tar.gz deleted file mode 100644 index 4bfcbc8e825a5ec05737fe78bb12136fb8ddd6a0..0000000000000000000000000000000000000000 Binary files a/pytest_asyncio-1.2.0.tar.gz and /dev/null differ diff --git a/pytest_asyncio-1.3.0.tar.gz b/pytest_asyncio-1.3.0.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..298b6fcf0d15a084e42eefd981d11f76a91f9ed3 Binary files /dev/null and b/pytest_asyncio-1.3.0.tar.gz differ diff --git a/python-pytest-asyncio.spec b/python-pytest-asyncio.spec index 8d374d34652fc73df81a67e5ec51e8ad3a86ed37..705a5952cd85ca80c8b539046094d5cf3d077ac9 100644 --- a/python-pytest-asyncio.spec +++ b/python-pytest-asyncio.spec @@ -1,11 +1,12 @@ %global _empty_manifest_terminate_build 0 +%undefine _python_dist_allow_version_zero Name: python-pytest-asyncio -Version: 1.2.0 +Version: 1.3.0 Release: 1 Summary: Pytest support for asyncio. License: Apache-2.0 URL: https://github.com/pytest-dev/pytest-asyncio -Source0: %{pypi_source pytest_asyncio} +Source0: https://files.pythonhosted.org/packages/source/p/pytest_asyncio/pytest_asyncio-%{version}.tar.gz BuildArch: noarch Requires: python3-pytest @@ -16,16 +17,21 @@ Requires: python3-flaky Requires: python3-mypy Requires: python3-pytest-trio +BuildRequires: python3-pip +BuildRequires: python3-wheel +BuildRequires: python3-build +BuildRequires: python3-hatchling +BuildRequires: python3-devel +BuildRequires: python3-pip python3-wheel python3-flit +BuildRequires: python3-pytest +BuildRequires: python3-setuptools python3-setuptools_scm + %description Pytest support for asyncio %package -n python3-pytest-asyncio Summary: Pytest support for asyncio Provides: python-pytest-asyncio = %{version}-%{release} -BuildRequires: python3-devel -BuildRequires: python3-pip python3-wheel python3-flit -BuildRequires: python3-pytest -BuildRequires: python3-setuptools python3-setuptools_scm %description -n python3-pytest-asyncio Pytest support for asyncio @@ -38,10 +44,28 @@ Pytest support for asyncio %prep %autosetup -p1 -n pytest_asyncio-%{version} +# Fix setuptools_scm version issue +if [ -f pyproject.toml ]; then + sed -i '/^version *=/d' pyproject.toml + sed -i '/^\[project\]/a version = "%{version}"' pyproject.toml + sed -i '/dynamic *= *\[.*version.*\]/d' pyproject.toml + if grep -q '^\[tool\.setuptools_scm\]' pyproject.toml; then + sed -i '/^\[tool\.setuptools_scm\]/,/^\[/ {/^write_to *=/d}' pyproject.toml + sed -i '/^\[tool\.setuptools_scm\]/a fallback_version = "%{version}"' pyproject.toml + fi +fi + %build +export SETUPTOOLS_SCM_PRETEND_VERSION="%{version}" %pyproject_build %install +export PYTHONDONTWRITEBYTECODE=1 + +# Clean __pycache__ directories and .pyc/.pyo files +find %{buildroot} -name '*.py[co]' -delete +find %{buildroot} -type d -name '__pycache__' -exec rm -rf {} + 2>/dev/null || true +export SETUPTOOLS_SCM_PRETEND_VERSION="%{version}" %pyproject_install pytest-asyncio==%{version} install -d -m755 %{buildroot}/%{_pkgdocdir} if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi @@ -55,6 +79,9 @@ if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi %{_docdir}/* %changelog +* Thu Nov 27 2025 zhangzeyang0718 - 1.3.0-1 +- Update package to version 1.3.0 + * Tue Oct 21 2025 dongjiao - 1.2.0-1 - Update package to version 1.2.0 * Compatibility with the Pyright type checker.