From 4e1352b4fd80df5ad039961bdcb734afe8c601c7e41f97fca0c3c5686432476a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Fri, 20 Mar 2020 12:06:28 +0000 Subject: [PATCH] Accepting request 786848 from home:mcalabkova:branches:devel:languages:python - Update to 4.0.0 * Drop Python2 * Support Python3.8 * Add type hints * Many fixes - Drop patch python38.patch OBS-URL: https://build.opensuse.org/request/show/786848 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pymarc?expand=0&rev=9 --- LICENSE | 46 +++++++++++++++++++++++++++++++++++++++++-- pymarc-3.1.13.tar.gz | 3 --- pymarc-4.0.0.tar.gz | 3 +++ python-pymarc.changes | 10 ++++++++++ python-pymarc.spec | 13 ++++++------ python38.patch | 24 ---------------------- 6 files changed, 63 insertions(+), 36 deletions(-) delete mode 100644 pymarc-3.1.13.tar.gz create mode 100644 pymarc-4.0.0.tar.gz delete mode 100644 python38.patch diff --git a/LICENSE b/LICENSE index 789b2a1..24572cb 100644 --- a/LICENSE +++ b/LICENSE @@ -1,5 +1,3 @@ -Copyright 2005-2019 Gabriel Farrell, Mark Matienzo, Geoffrey Spear, Ed Summers - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -20,3 +18,47 @@ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Copyright for this project is held by its many contributors, including: + +Adam Constabaris +André Nesse +Chris Adams +Dan Chudnov +Dan Michael O. Heggø +Dan Scott +David Chouinard +Ed Hill +Ed Summers +Edward Betts +Eric Hellman +Gabriel Farrell +Geoffrey Spear +Godmar Back +Helga +James Tayson +Jay Luker +Jim Nicholls +Karol Sikora +Lucas Souza +Mark A. Matienzo +Martin Czygan +Michael B. Klein +Michael J. Giarlo +Mikhail Terekhov +Nick Ruest +Pierre Verkest +Radim Řehůřek +Renaud Boyer +Robert Marchman +Sean Chen +Simon Hohl +Ted Lawless +Victor Seva +Will Earp +cclauss +cyperus-papyrus +gitgovdoc +mmh +nemobis +wrCisco diff --git a/pymarc-3.1.13.tar.gz b/pymarc-3.1.13.tar.gz deleted file mode 100644 index cba0096..0000000 --- a/pymarc-3.1.13.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9a673c4fd39cb2cb80b3070f04c9bc015a4aa09c4b7daa0dffe3b3695e9d6c7b -size 214294 diff --git a/pymarc-4.0.0.tar.gz b/pymarc-4.0.0.tar.gz new file mode 100644 index 0000000..c67e9d2 --- /dev/null +++ b/pymarc-4.0.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5abe4d9243babd89811ddb3b841e3dbc18ae5dc6c062813e102bf42e0b09067 +size 227485 diff --git a/python-pymarc.changes b/python-pymarc.changes index e72329a..eebdbac 100644 --- a/python-pymarc.changes +++ b/python-pymarc.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Fri Mar 20 11:51:32 UTC 2020 - Marketa Calabkova + +- Update to 4.0.0 + * Drop Python2 + * Support Python3.8 + * Add type hints + * Many fixes +- Drop patch python38.patch + ------------------------------------------------------------------- Fri Dec 6 07:42:48 UTC 2019 - Tomáš Chvátal diff --git a/python-pymarc.spec b/python-pymarc.spec index 51628b7..30f8a60 100644 --- a/python-pymarc.spec +++ b/python-pymarc.spec @@ -1,7 +1,7 @@ # # spec file for package python-pymarc # -# Copyright (c) 2019 SUSE LLC +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,8 +17,9 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} +%define skip_python2 1 Name: python-pymarc -Version: 3.1.13 +Version: 4.0.0 Release: 0 Summary: MARC bibliographic data manipulation module License: BSD-2-Clause @@ -26,14 +27,13 @@ Group: Development/Languages/Python URL: https://github.com/edsu/pymarc Source: https://files.pythonhosted.org/packages/source/p/pymarc/pymarc-%{version}.tar.gz Source1: https://raw.githubusercontent.com/edsu/pymarc/master/LICENSE -Patch0: python38.patch BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: python-six >= 1.9.0 +Requires: python-pytest BuildArch: noarch # SECTION test requirements -BuildRequires: %{python_module six >= 1.9.0} +BuildRequires: %{python_module pytest} # /SECTION %python_subpackages @@ -46,7 +46,6 @@ saner representation. %prep %setup -q -n pymarc-%{version} -%patch0 -p1 cp %{SOURCE1} . %build @@ -57,7 +56,7 @@ cp %{SOURCE1} . %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -%python_exec setup.py test +%pytest %files %{python_files} %doc README.md diff --git a/python38.patch b/python38.patch deleted file mode 100644 index 79463f5..0000000 --- a/python38.patch +++ /dev/null @@ -1,24 +0,0 @@ -From 44d37f6aef231e1b874f2c12e002007d686da28e Mon Sep 17 00:00:00 2001 -From: Geoffrey Spear -Date: Mon, 7 Oct 2019 08:33:07 -0400 -Subject: [PATCH 1/2] test on 3.8-dev - ---- - pymarc/marcxml.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/pymarc/marcxml.py b/pymarc/marcxml.py -index 7d87905..f351a8b 100644 ---- a/pymarc/marcxml.py -+++ b/pymarc/marcxml.py -@@ -160,9 +160,9 @@ def translate(data): - control_field.text = translate(field.data) - else: - data_field = ET.SubElement(root, 'datafield') -- data_field.set('tag', field.tag) - data_field.set('ind1', field.indicators[0]) - data_field.set('ind2', field.indicators[1]) -+ data_field.set('tag', field.tag) - for subfield in field: - data_subfield = ET.SubElement(data_field, 'subfield') - data_subfield.set('code', subfield[0])