a5fa8f
%global modname attrs
a5fa8f
a5fa8f
Name:           python-attrs
a5fa8f
Version:        17.4.0
a5fa8f
Release:        6%{?dist}
a5fa8f
Summary:        Python attributes without boilerplate
a5fa8f
a5fa8f
License:        MIT
a5fa8f
URL:            http://www.attrs.org/
a5fa8f
BuildArch:      noarch
a5fa8f
Source0:        https://github.com/hynek/%{modname}/archive/%{version}/%{modname}-%{version}.tar.gz
a5fa8f
a5fa8f
a5fa8f
BuildRequires:  python%{python3_pkgversion}-devel
a5fa8f
BuildRequires:  python%{python3_pkgversion}-setuptools
a5fa8f
BuildRequires:  python%{python3_pkgversion}-pytest
a5fa8f
BuildRequires:  python%{python3_pkgversion}-hypothesis
a5fa8f
BuildRequires:  python%{python3_pkgversion}-six
a5fa8f
a5fa8f
%if 0%{?rhel}
a5fa8f
# can't run validator tests on EL without python-zope-interface
a5fa8f
%else
a5fa8f
BuildRequires:  python%{python3_pkgversion}-zope-interface
a5fa8f
%endif
a5fa8f
a5fa8f
%description
a5fa8f
attrs is an MIT-licensed Python package with class decorators that
a5fa8f
ease the chores of implementing the most common attribute-related
a5fa8f
object protocols.
a5fa8f
a5fa8f
%package -n python%{python3_pkgversion}-%{modname}
a5fa8f
Summary:        %{summary}
a5fa8f
%{?python_provide:%python_provide python%{python3_pkgversion}-%{modname}}
a5fa8f
a5fa8f
%description -n python%{python3_pkgversion}-%{modname}
a5fa8f
attrs is an MIT-licensed Python package with class decorators that
a5fa8f
ease the chores of implementing the most common attribute-related
a5fa8f
object protocols.
a5fa8f
a5fa8f
%prep
a5fa8f
%setup -q -n %{modname}-%{version}
a5fa8f
a5fa8f
%if 0%{?rhel}
a5fa8f
# can't run validator tests on EL without python-zope-interface
a5fa8f
rm tests/test_validators.py
a5fa8f
%endif
a5fa8f
a5fa8f
%build
a5fa8f
%py3_build
a5fa8f
a5fa8f
%install
a5fa8f
%py3_install
a5fa8f
a5fa8f
%check
a5fa8f
%if 0%{?rhel} && 0%{?rhel} <= 7
a5fa8f
# Can't run tests on EPEL7 due to need for pytest >= 2.8
a5fa8f
%else
a5fa8f
PYTHONPATH=%{buildroot}/%{python3_sitelib} py.test-3 -v
a5fa8f
%endif
a5fa8f
a5fa8f
%files -n python%{python3_pkgversion}-%{modname}
a5fa8f
%license LICENSE
a5fa8f
%doc AUTHORS.rst README.rst
a5fa8f
%{python3_sitelib}/*
a5fa8f
a5fa8f
%changelog
a5fa8f
* Mon Jul 09 2018 Petr Viktorin <pviktori@redhat.com> - 17.4.0-6
a5fa8f
- Remove python2 subpackage
a5fa8f
  https://bugzilla.redhat.com/show_bug.cgi?id=1590809
a5fa8f
a5fa8f
* Mon Jun 25 2018 Petr Viktorin <pviktori@redhat.com> - 17.4.0-5
a5fa8f
- Allow Python 2 for build
a5fa8f
  see https://hurl.corp.redhat.com/rhel8-py2
a5fa8f
a5fa8f
* Fri Jun 22 2018 Petr Viktorin <pviktori@redhat.com> - 17.4.0-4
a5fa8f
- Remove the python2-hypothesis circular build dependency
a5fa8f
a5fa8f
* Thu Jun 14 2018 Petr Viktorin <pviktori@redhat.com> - 17.4.0-3
a5fa8f
- Remove the python-zope-interface build dependency
a5fa8f
a5fa8f
* Wed Jan 17 2018 Eric Smith <brouhaha@fedoraproject.org> 17.4.0-2
a5fa8f
- Added BuildRequires for python<n>-six.
a5fa8f
a5fa8f
* Thu Jan 11 2018 Eric Smith <brouhaha@fedoraproject.org> 17.4.0-1
a5fa8f
- Updated to latest upstream.
a5fa8f
a5fa8f
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 16.3.0-3
a5fa8f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
a5fa8f
a5fa8f
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 16.3.0-2
a5fa8f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
a5fa8f
a5fa8f
* Wed Dec 14 2016 Eric Smith <brouhaha@fedoraproject.org> 16.3.0-1
a5fa8f
- Updated to latest upstream.
a5fa8f
a5fa8f
* Tue Dec 13 2016 Charalampos Stratakis <cstratak@redhat.com> - 16.1.0-3
a5fa8f
- Enable tests
a5fa8f
a5fa8f
* Mon Dec 12 2016 Charalampos Stratakis <cstratak@redhat.com> - 16.1.0-2
a5fa8f
- Rebuild for Python 3.6
a5fa8f
- Disable python3 tests for now
a5fa8f
a5fa8f
* Sat Sep 10 2016 Eric Smith <brouhaha@fedoraproject.org> 16.1.0-1
a5fa8f
- Updated to latest upstream.
a5fa8f
- Removed patch, no longer necessary.
a5fa8f
- Removed "with python3" conditionals.
a5fa8f
a5fa8f
* Thu Aug 18 2016 Eric Smith <brouhaha@fedoraproject.org> 16.0.0-6
a5fa8f
- Build for Python 3.4 in EPEL7.
a5fa8f
a5fa8f
* Thu Aug 18 2016 Eric Smith <brouhaha@fedoraproject.org> 16.0.0-5
a5fa8f
- Updated based on Fedora package review (#1366878).
a5fa8f
- Fix check section, though tests can not be run for EPEL7.
a5fa8f
- Add patch to skip two tests with keyword collisions.
a5fa8f
a5fa8f
* Tue Aug 16 2016 Eric Smith <brouhaha@fedoraproject.org> 16.0.0-4
a5fa8f
- Fix python2 BuildRequires.
a5fa8f
a5fa8f
* Mon Aug 15 2016 Eric Smith <brouhaha@fedoraproject.org> 16.0.0-3
a5fa8f
- Updated based on Fedora package review (#1366878).
a5fa8f
a5fa8f
* Sun Aug 14 2016 Eric Smith <brouhaha@fedoraproject.org> 16.0.0-2
a5fa8f
- Updated based on Fedora package review (#1366878).
a5fa8f
a5fa8f
* Sat Aug 13 2016 Eric Smith <brouhaha@fedoraproject.org> 16.0.0-1
a5fa8f
- Initial version.