[packages/python3-elementpath] - python-elementpath.spec updated to 2.0.3 for python 3.5+ - removed obsolete hash patch
qboosh
qboosh at pld-linux.org
Fri Sep 18 19:47:39 CEST 2020
commit 814fb68529c446b42f49436656ce52b3b2f85616
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Fri Sep 18 19:48:29 2020 +0200
- python-elementpath.spec updated to 2.0.3 for python 3.5+
- removed obsolete hash patch
python-elementpath-hash.patch | 26 -----------------
python3-elementpath.spec | 66 +++----------------------------------------
2 files changed, 4 insertions(+), 88 deletions(-)
---
diff --git a/python3-elementpath.spec b/python3-elementpath.spec
index 4fae049..d4e63e2 100644
--- a/python3-elementpath.spec
+++ b/python3-elementpath.spec
@@ -2,41 +2,29 @@
# Conditional build:
%bcond_without doc # Sphinx documentation
%bcond_without tests # unit tests
-%bcond_without python2 # CPython 2.x module
-%bcond_without python3 # CPython 3.x module
Summary: XPath 1.0/2.0 parsers and selectors for ElementTree and lxml
Summary(pl.UTF-8): Parsery i selektory XPath 1.0/2.0 dla ElementTree oraz lxml
-Name: python-elementpath
-Version: 1.3.3
+Name: python3-elementpath
+Version: 2.0.3
Release: 1
License: MIT
Group: Libraries/Python
#Source0Download: https://pypi.org/simple/elementpath/
Source0: https://files.pythonhosted.org/packages/source/e/elementpath/elementpath-%{version}.tar.gz
-# Source0-md5: 3712104ae5970878a112c31aea71a503
-Patch0: %{name}-hash.patch
+# Source0-md5: 65e7c7f6394d4d596888359cc291fc1d
URL: https://pypi.org/project/elementpath/
-%if %{with python2}
-BuildRequires: python-modules >= 1:2.7
-BuildRequires: python-setuptools
-%if %{with tests}
-BuildRequires: python-lxml
-%endif
-%endif
-%if %{with python3}
BuildRequires: python3-modules >= 1:3.5
BuildRequires: python3-setuptools
%if %{with tests}
BuildRequires: python3-lxml
%endif
-%endif
BuildRequires: rpm-pythonprov
BuildRequires: rpmbuild(macros) >= 1.714
%if %{with doc}
BuildRequires: sphinx-pdg
%endif
-Requires: python-modules >= 1:2.7
+Requires: python3-modules >= 1:3.5
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -50,22 +38,6 @@ Celem tego pakietu jest udostępnienie selektorów XPath 1.0 i 2.0 do
pythonowych struktur danych XML ElementTree, zarówno dla ElementTree z
biblioteki strandardowej, jak i lxml.etree.
-%package -n python3-elementpath
-Summary: XPath 1.0/2.0 parsers and selectors for ElementTree and lxml
-Summary(pl.UTF-8): Parsery i selektory XPath 1.0/2.0 dla ElementTree oraz lxml
-Group: Libraries/Python
-Requires: python3-modules >= 1:3.5
-
-%description -n python3-elementpath
-The proposal of this package is to provide XPath 1.0 and 2.0 selectors
-for Python's ElementTree XML data structures, both for the standard
-ElementTree library and for the lxml.etree library.
-
-%description -n python3-elementpath -l pl.UTF-8
-Celem tego pakietu jest udostępnienie selektorów XPath 1.0 i 2.0 do
-pythonowych struktur danych XML ElementTree, zarówno dla ElementTree z
-biblioteki strandardowej, jak i lxml.etree.
-
%package apidocs
Summary: API documentation for Python elementpath module
Summary(pl.UTF-8): Dokumentacja API modułu Pythona elementpath
@@ -79,25 +51,13 @@ Dokumentacja API modułu Pythona elementpath.
%prep
%setup -q -n elementpath-%{version}
-%patch0 -p1
%build
-%if %{with python2}
-%py_build
-
-%if %{with tests}
-PYTHONPATH=$(pwd) \
-%{__python} tests/test_elementpath.py
-%endif
-%endif
-
-%if %{with python3}
%py3_build
%if %{with tests}
%{__python3} -m unittest
%endif
-%endif
%if %{with doc}
%{__make} -C doc html
@@ -106,34 +66,16 @@ PYTHONPATH=$(pwd) \
%install
rm -rf $RPM_BUILD_ROOT
-%if %{with python2}
-%py_install
-
-%py_postclean
-%endif
-
-%if %{with python3}
%py3_install
-%endif
%clean
rm -rf $RPM_BUILD_ROOT
-%if %{with python2}
%files
%defattr(644,root,root,755)
%doc CHANGELOG.rst LICENSE README.rst
-%{py_sitescriptdir}/elementpath
-%{py_sitescriptdir}/elementpath-%{version}-py*.egg-info
-%endif
-
-%if %{with python3}
-%files -n python3-elementpath
-%defattr(644,root,root,755)
-%doc CHANGELOG.rst LICENSE README.rst
%{py3_sitescriptdir}/elementpath
%{py3_sitescriptdir}/elementpath-%{version}-py*.egg-info
-%endif
%if %{with doc}
%files apidocs
diff --git a/python-elementpath-hash.patch b/python-elementpath-hash.patch
deleted file mode 100644
index 279157c..0000000
--- a/python-elementpath-hash.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- elementpath-1.3.3/tests/test_datatypes.py.orig 2019-10-21 14:02:17.000000000 +0200
-+++ elementpath-1.3.3/tests/test_datatypes.py 2020-09-18 10:17:58.564091550 +0200
-@@ -597,10 +597,7 @@
- self.assertEqual(YearMonthDuration(10).months, 10)
-
- def test_hashing(self):
-- if sys.version_info < (3, 8):
-- self.assertEqual(hash(Duration(16)), 3713063228956366931)
-- else:
-- self.assertEqual(hash(Duration(16)), 6141449309508620102)
-+ self.assertIsInstance(hash(Duration(16)), int)
-
-
- class TimezoneTypeTest(unittest.TestCase):
-@@ -647,10 +644,7 @@
- self.assertNotEqual(Timezone.fromstring('+05:00'), Timezone.fromstring('+06:00'))
-
- def test_hashing(self):
-- if sys.version_info < (3, 8):
-- self.assertEqual(hash(Timezone.fromstring('+05:00')), 1289844826723787395)
-- else:
-- self.assertEqual(hash(Timezone.fromstring('+05:00')), 7009945331308913293)
-+ self.assertIsInstance(hash(Timezone.fromstring('+05:00')), int)
-
-
- class TypeProxiesTest(unittest.TestCase):
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python3-elementpath.git/commitdiff/814fb68529c446b42f49436656ce52b3b2f85616
More information about the pld-cvs-commit
mailing list