Accepting request 841417 from devel:languages:python

- skip tests that fail on 32bit 

- update to 0.14:
  * python 3.8 support
  * Various improvements w.r.t. type annotations & typing
  * Fix pure-Python implementation to accept keyword argument
  * Fix the mutation API to maintain elements count correctly
  * Allow None to be used as key in pure-Python implementation.
- remove py38.patch (upstream)

OBS-URL: https://build.opensuse.org/request/show/841417
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-immutables?expand=0&rev=4
This commit is contained in:
Dominique Leuenberger 2020-10-29 08:47:45 +00:00 committed by Git OBS Bridge
commit 31216c5f59
5 changed files with 25 additions and 29 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d6850578a0dc6530ac19113cfe4ddc13903df635212d498f176fe601a8a5a4a3
size 38557

3
immutables-0.14.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a0a1cc238b678455145bae291d8426f732f5255537ed6a5b7645949704c70a78
size 42983

View File

@ -1,23 +0,0 @@
From 2b52677fdde34b1c89bdf4411ef95bd1ed0f343d Mon Sep 17 00:00:00 2001
From: Bruno Oliveira <nicoddemus@gmail.com>
Date: Sat, 2 Nov 2019 17:56:24 -0300
Subject: [PATCH] Add Python 3.8 support (#16)
Fix #15
---
tests/test_map.py | 2 +-
4 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/tests/test_map.py b/tests/test_map.py
index 8d629f84..0b464cf2 100644
--- a/tests/test_map.py
+++ b/tests/test_map.py
@@ -1294,7 +1294,7 @@ def test_map_pickle(self):
self.assertTrue(isinstance(uh, self.Map))
self.assertEqual(h, uh)
- with self.assertRaisesRegex(TypeError, "can't pickle"):
+ with self.assertRaisesRegex(TypeError, "can('t|not) pickle"):
pickle.dumps(h.mutate())
@unittest.skipIf(sys.version_info < (3, 7, 0), "__class_getitem__ is not available")

View File

@ -1,3 +1,19 @@
-------------------------------------------------------------------
Tue Oct 13 07:42:13 UTC 2020 - Dirk Mueller <dmueller@suse.com>
- skip tests that fail on 32bit
-------------------------------------------------------------------
Wed Sep 16 11:27:37 UTC 2020 - Dirk Mueller <dmueller@suse.com>
- update to 0.14:
* python 3.8 support
* Various improvements w.r.t. type annotations & typing
* Fix pure-Python implementation to accept keyword argument
* Fix the mutation API to maintain elements count correctly
* Allow None to be used as key in pure-Python implementation.
- remove py38.patch (upstream)
-------------------------------------------------------------------
Mon Mar 9 08:33:40 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>

View File

@ -19,13 +19,12 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name: python-immutables
Version: 0.11
Version: 0.14
Release: 0
Summary: Immutable collections for Python
License: Apache-2.0
URL: https://github.com/MagicStack/immutables
Source: https://files.pythonhosted.org/packages/source/i/immutables/immutables-%{version}.tar.gz
Patch0: py38.patch
BuildRequires: %{python_module devel}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
@ -37,7 +36,6 @@ Immutable collections for Python.
%prep
%setup -q -n immutables-%{version}
%patch0 -p1
sed -i 's/\.system//' setup.py
%build
@ -51,6 +49,11 @@ export CFLAGS="%{optflags}"
}
%check
# Fails on 32bit for some reason
%ifarch %ix86
rm -v tests/test_none_keys.py
%endif
%python_exec setup.py test
%files %{python_files}