diff --git a/python-pydocstyle.spec b/python-pydocstyle.spec index 3b7fafe..c2e038c 100644 --- a/python-pydocstyle.spec +++ b/python-pydocstyle.spec @@ -3,7 +3,7 @@ Name: python-%{srcname} Version: 2.0.0 -Release: 6%{?dist} +Release: 7%{?dist} Summary: %{sum} License: MIT @@ -23,34 +23,6 @@ It supports most of PEP 257 out of the box, but it should not be considered a reference implementation. -%package -n python2-%{srcname} -Summary: %{sum} -%{?python_provide:%python_provide python2-%{srcname}} - -BuildRequires: python2-devel -# Required for running tests -BuildRequires: python2-six -BuildRequires: python2-snowballstemmer -BuildRequires: python2-pytest -BuildRequires: python2-pytest-pep8 -BuildRequires: python2-mock -# NOTE: pathlib is not in BuildRequires since it is only needed by Integration -# tests which are ignored on Python 2 due to reasons described below. - -Requires: python2-six -Requires: python2-snowballstemmer - -%description -n python2-%{srcname} -A static analysis tool for checking compliance with Python docstring -conventions. - -It supports most of PEP 257 out of the box, but it should not be considered a -reference implementation. - -NOTE: Only Python 3 version of 'pydocstyle' executable is packaged. See: -python3-%{srcname}. - - %package -n python3-%{srcname} Summary: %{sum} %{?python_provide:%python_provide python3-%{srcname}} @@ -81,7 +53,6 @@ reference implementation. %build -%py2_build %py3_build # Remove (incorrect) Python shebang from package's __main__.py file @@ -89,27 +60,10 @@ sed -i '\|/usr/bin/env|d' build/lib/pydocstyle/__main__.py %install -# Must do the python2 install first because the scripts in /usr/bin are -# overwritten with every setup.py install, and in general we want the -# python3 version to be the default. -%py2_install %py3_install %check -# Run tests under Python 2 - -# NOTE: Integration tests are ignored on Python 2 since they require having the -# 'pydocstyle' executable installed on the system. As described below, we only -# package Python 3 version of this executable. -# NOTE: We need to specify the PYTHONPATH environment variable so that Python -# can find the system-installed pydocstyle package in %%{buildroot}. -PYTHONPATH="%{buildroot}%{python2_sitelib}" py.test \ - --pep8 \ - --cache-clear \ - --ignore=src/tests/test_integration.py \ - src/tests - # Run tests under Python 3 # Disable "install_package" fixure for integration tests since we want the @@ -131,18 +85,11 @@ sed -E -i 's|"python(2\|3)*( -m pydocstyle)|"%{__python3}\2|' \ PYTHONPATH="%{buildroot}%{python3_sitelib}" PATH="$PATH:%{buildroot}%{_bindir}" py.test-3 \ --pep8 \ --cache-clear \ - src/tests + src/tests -v # NOTE: There is no %%files section for the unversioned python module if we are # building for several python runtimes -%files -n python2-%{srcname} -%license LICENSE-MIT -%doc README.rst -%{python2_sitelib}/* -# NOTE: Only Python 3 versions of executables are packaged as recommended in: -# https://fedoraproject.org/wiki/Packaging:Python#Executables_in_.2Fusr.2Fbin - %files -n python3-%{srcname} %license LICENSE-MIT %doc README.rst @@ -151,6 +98,10 @@ PYTHONPATH="%{buildroot}%{python3_sitelib}" PATH="$PATH:%{buildroot}%{_bindir}" %changelog +* Thu Oct 11 2018 Zbigniew Jędrzejewski-Szmek - 2.0.0-7 +- Python2 binary package has been removed + See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal + * Sat Jul 14 2018 Fedora Release Engineering - 2.0.0-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild