0708ae9
%bcond_with    python2
0708ae9
%bcond_without python3
0708ae9
1057da6
%global modname marshmallow
1057da6
%global _docdir_fmt %{name}
1057da6
1057da6
Name:           python-%{modname}
Miroslav Suchý cbeb48a
Version:        3.5.1
f6aafb0
Release:        3%{?dist}
4326bfd
Summary:        Python library for converting complex datatypes to and from primitive types
4326bfd
License:        MIT
4326bfd
URL:            http://marshmallow.readthedocs.org/
1057da6
Source0:        https://github.com/marshmallow-code/marshmallow/archive/%{version}/%{modname}-%{version}.tar.gz
0904585
Patch0:         ordered_set.patch
0904585
Patch1:         versionwarning-disable.patch
1057da6
4326bfd
BuildArch:      noarch
1057da6
1057da6
%global _description \
1057da6
Marshmallow is a framework-agnostic library for converting complex datatypes,\
1057da6
such as objects, to and from primitive Python datatypes.\
1057da6
\
1057da6
Marshmallow schemas can be used to:\
1057da6
* Validate input data.\
1057da6
* Deserialize input data to app-level objects.\
1057da6
* Serialize app-level objects to primitive Python types. The serialized objects\
1057da6
  can then be rendered to standard formats such as JSON for use in an HTTP API.
1057da6
1057da6
%description %{_description}
1057da6
1057da6
%package doc
1057da6
Summary:        Documentation for %{name}
459caa5
Provides:       python3-%{modname}-doc = %{version}
1057da6
Obsoletes:      python3-%{modname}-doc < 2.8.0-1
0708ae9
BuildRequires:  python3-sphinx
1057da6
1057da6
%description doc
1057da6
Documentation for %{name}.
1057da6
0708ae9
0708ae9
%if %{with python2}
1057da6
%package -n python2-%{modname}
1057da6
Summary:        %{summary}
1057da6
%{?python_provide:%python_provide python2-%{modname}}
4326bfd
BuildRequires:  python2-devel
1057da6
BuildRequires:  python2-setuptools
4326bfd
# for tests
1057da6
BuildRequires:  python2-pytest
1057da6
BuildRequires:  python2-pytz
ffba147
BuildRequires:  python2-ordered-set
1057da6
BuildRequires:  python2-dateutil
ffba147
BuildRequires:  python2-simplejson
ffba147
Requires:       python2-ordered-set
1057da6
Recommends:     python2-dateutil
ffba147
Recommends:     python2-simplejson
1057da6
1057da6
%description -n python2-%{modname} %{_description}
1057da6
1057da6
Python 2 version.
0708ae9
%endif
1057da6
0708ae9
0708ae9
%if %{with python3}
1057da6
%package -n python3-%{modname}
1057da6
Summary:        %{summary}
1057da6
%{?python_provide:%python_provide python3-%{modname}}
4326bfd
BuildRequires:  python3-devel
4326bfd
BuildRequires:  python3-setuptools
4326bfd
# for tests
4326bfd
BuildRequires:  python3-pytest
4326bfd
BuildRequires:  python3-pytz
4326bfd
BuildRequires:  python3-ordered-set
1057da6
BuildRequires:  python3-dateutil
336fe9a
BuildRequires:  python3-simplejson
4326bfd
Requires:       python3-ordered-set
1057da6
Recommends:     python3-dateutil
1057da6
Recommends:     python3-simplejson
4326bfd
1057da6
%description -n python3-%{modname} %{_description}
4326bfd
1057da6
Python 3 version.
0708ae9
%endif
4326bfd
4326bfd
%prep
286f754
%autosetup -n %{modname}-%{version} -p1
4326bfd
4326bfd
# remove bundled library
4326bfd
# instead of orderedsett we patch code to usu python-ordered-set
0904585
rm -f ./marshmallow/orderedset.py
4326bfd
1057da6
# Drop support for sphinx-issues as it's not yet packaged
1057da6
sed -i -e "/sphinx_issues/d" docs/conf.py
4326bfd
a9a4600
# unsupported theme option 'donate_url' given
a9a4600
sed -i -e "/donate_url/d" docs/conf.py
a9a4600
4326bfd
%build
0708ae9
%{?with_python2:%py2_build}
0708ae9
%{?with_python3:%py3_build}
Igor Gnatenko 020ea34
sphinx-build -b html docs html
4326bfd
4326bfd
%install
0708ae9
%{?with_python2:%py2_install}
0708ae9
%{?with_python3:%py3_install}
1057da6
rm -rf html/{.buildinfo,.doctrees}
4326bfd
0708ae9
4326bfd
%check
0708ae9
%{?with_python2:py.test-%{python2_version} -v --ignore tests/test_py3/}
0708ae9
%{?with_pythoN3:py.test-%{python3_version} -v}
0708ae9
4326bfd
4326bfd
%files doc
4326bfd
%license LICENSE
1057da6
%doc html examples
1057da6
0708ae9
0708ae9
%if %{with python2}
1057da6
%files -n python2-%{modname}
4326bfd
%license LICENSE
1057da6
%doc CHANGELOG.rst README.rst
1057da6
%{python2_sitelib}/%{modname}/
1057da6
%{python2_sitelib}/%{modname}-*.egg-info/
0708ae9
%endif
4326bfd
0708ae9
%if %{with python3}
1057da6
%files -n python3-%{modname}
4326bfd
%license LICENSE
1057da6
%doc CHANGELOG.rst README.rst
1057da6
%{python3_sitelib}/%{modname}/
1057da6
%{python3_sitelib}/%{modname}-*.egg-info/
0708ae9
%endif
0708ae9
4326bfd
4326bfd
%changelog
f6aafb0
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.1-3
f6aafb0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
f6aafb0
d279217
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 3.5.1-2
d279217
- Rebuilt for Python 3.9
d279217
Miroslav Suchý cbeb48a
* Tue Mar 24 2020 Miroslav Suchý <miroslav@suchy.cz> 3.5.1-1
Miroslav Suchý cbeb48a
- rebase to 3.5.1
Miroslav Suchý cbeb48a
f2d8e06
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.1-2
f2d8e06
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
f2d8e06
0904585
* Mon Sep 16 2019 Miroslav Suchý <msuchy@redhat.com> 3.1.1-1
0904585
- rebase to python-marshmallow 3.1.1
0904585
76b1852
* Wed Aug 21 2019 Miro Hrončok <mhroncok@redhat.com> - 2.20.0-2
76b1852
- Rebuilt for Python 3.8
76b1852
eda5d7e
* Mon Aug 19 2019 Pavel Raiskup <praiskup@redhat.com> - 2.20.0-1
eda5d7e
- latest upstream release
eda5d7e
3632a26
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 2.19.4-3
3632a26
- Rebuilt for Python 3.8
3632a26
e6c47c1
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.19.4-2
e6c47c1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
e6c47c1
1a3a665
* Mon Jun 17 2019 Pavel Raiskup <praiskup@redhat.com> - 2.19.4-1
1afd44c
- new upstream release
1afd44c
286f754
* Sun Mar 31 2019 Pavel Raiskup <praiskup@redhat.com> - 2.19.2-1
286f754
- new upstream release
286f754
197a08c
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.11.1-10
197a08c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
197a08c
0708ae9
* Wed Nov 14 2018 Pavel Raiskup <praiskup@redhat.com> - 2.11.1-9
0708ae9
- add rpmbuild --wit{,hout}=python{2,3} options
0708ae9
- generate docs by python3-sphinx
0708ae9
- don't build Python 2 subpackage by default
0708ae9
b4ff4c6
* Fri Sep 21 2018 Miroslav Suchý <msuchy@redhat.com> 2.11.1-8
b4ff4c6
- add patch for CVE-2018-17175.patch
b4ff4c6
3686032
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.11.1-7
3686032
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
3686032
402f523
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 2.11.1-6
402f523
- Rebuilt for Python 3.7
402f523
30ee1bc
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.11.1-5
30ee1bc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
30ee1bc
ffba147
* Thu Jan 25 2018 Iryna Shcherbina <ishcherb@redhat.com> - 2.11.1-4
ffba147
- Update Python 2 dependency declarations to new packaging standards
ffba147
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
ffba147
17b0a8c
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.11.1-3
17b0a8c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
17b0a8c
d37f802
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.11.1-2
d37f802
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
d37f802
Igor Gnatenko 7470739
* Mon Jan 09 2017 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.11.1-1
Igor Gnatenko 7470739
- Update to 2.11.1 (RHBZ #1411181)
Igor Gnatenko 7470739
Igor Gnatenko 3afd023
* Tue Dec 27 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.10.5-1
Igor Gnatenko 3afd023
- Update to 2.10.5 (RHBZ #1408340)
Igor Gnatenko 3afd023
b0b66fc
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 2.10.4-2
b0b66fc
- Rebuild for Python 3.6
b0b66fc
Igor Gnatenko 8c7a1d1
* Thu Dec 01 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.10.4-1
Igor Gnatenko 8c7a1d1
- Update to 2.10.4 (RHBZ #1400189)
Igor Gnatenko 8c7a1d1
Igor Gnatenko 653a291
* Tue Oct 04 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.10.3-1
Igor Gnatenko 653a291
- Update to 2.10.3 (RHBZ #1381098)
Igor Gnatenko 653a291
Igor Gnatenko e6392be
* Thu Sep 15 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.10.1-2
Igor Gnatenko e6392be
- Update to 2.10.1 (RHBZ #1376432)
Igor Gnatenko e6392be
Igor Gnatenko 020ea34
* Tue Sep 06 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.10.0-2
Igor Gnatenko 020ea34
- Trivial fix in spec
Igor Gnatenko 020ea34
Igor Gnatenko 81755b4
* Tue Sep 06 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.10.0-1
Igor Gnatenko 81755b4
- Update to 2.10.0
Igor Gnatenko 81755b4
77a2bd3
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.9.0-2
77a2bd3
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
77a2bd3
Igor Gnatenko ec4341d
* Thu Jul 07 2016 Igor Gnatenko <ignatenko@redhat.com> - 2.9.0-1
Igor Gnatenko ec4341d
- Update to 2.9.0
Igor Gnatenko ec4341d
1057da6
* Wed Jul 06 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 2.8.0-1
1057da6
- Update to 2.8.0
1057da6
- Add recommends
1057da6
- Modernize spec
1057da6
989c952
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.2.1-0.3.gitea1def9
989c952
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
989c952
336fe9a
* Wed Nov 18 2015 Miroslav Suchý <msuchy@redhat.com> 2.2.1-0.2.gitea1def9
336fe9a
- add BR simplejson
336fe9a
- add BR python-tox
336fe9a
b48e7f2
* Wed Nov 18 2015 Miroslav Suchý <msuchy@redhat.com> 2.2.1-0.1.gitea1def9
b48e7f2
- rebase to 2.2.1
b48e7f2
b48e7f2
* Wed Nov 18 2015 Miroslav Suchý <miroslav@suchy.cz> 2.2.1-0.0.gitea1def9
b48e7f2
- rebase to 2.2.1
5e909d3
4326bfd
* Fri Sep 11 2015 Miroslav Suchý <miroslav@suchy.cz> 2.0.0-0.6.gita8b3385
4326bfd
- 1219288 - fix ownership of docdir and use correct release number
4326bfd
4326bfd
* Fri Sep 11 2015 Miroslav Suchý <msuchy@redhat.com> 2.0.0-0.5.a8b3385
4326bfd
- add short git hash to release number
4326bfd
4326bfd
* Fri Sep 11 2015 Miroslav Suchý <msuchy@redhat.com> 2.0.0b5-4
4326bfd
- create -doc subpackages
4326bfd
- 1219288 - reorganize spec file
4326bfd
4326bfd
* Mon Sep 07 2015 Miroslav Suchý <msuchy@redhat.com> 2.0.0b5-3
4326bfd
- explicitely list docdir
4326bfd
4326bfd
* Mon Sep 07 2015 Miroslav Suchý <msuchy@redhat.com> 2.0.0b5-2
4326bfd
- unbundle ordereddict and ordered set
4326bfd
- add documentation
4326bfd
4326bfd
* Mon Aug 24 2015 Valentin Gologuzov <vgologuz@redhat.com> - 2.0.0b5-1
4326bfd
- Rebuild with the newest upstream version
4326bfd
4326bfd
* Thu May 07 2015 Dan Callaghan <dcallagh@redhat.com> - 1.2.6-1
4326bfd
- initial version