Hello community,

here is the log from the commit of package python-scikit-image for 
openSUSE:Factory checked in at 2019-08-05 10:36:11
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-scikit-image (Old)
 and      /work/SRC/openSUSE:Factory/.python-scikit-image.new.4126 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-scikit-image"

Mon Aug  5 10:36:11 2019 rev:8 rq:720126 version:0.15.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-scikit-image/python-scikit-image.changes  
2019-07-29 17:31:41.974149902 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-scikit-image.new.4126/python-scikit-image.changes
        2019-08-05 10:36:21.819334667 +0200
@@ -1,0 +2,7 @@
+Wed Jul 31 20:59:24 UTC 2019 - Todd R <[email protected]>
+
+- Add fix_numpy_1_17.patch 
+  Fixes building with numpy 1.17
+  From gh#scikit-image/scikit-image#3992
+
+-------------------------------------------------------------------

New:
----
  fix_numpy_1_17.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-scikit-image.spec ++++++
--- /var/tmp/diff_new_pack.4ecr0o/_old  2019-08-05 10:36:23.715334450 +0200
+++ /var/tmp/diff_new_pack.4ecr0o/_new  2019-08-05 10:36:23.743334447 +0200
@@ -28,6 +28,8 @@
 Source0:        
https://files.pythonhosted.org/packages/source/s/scikit-image/scikit-image-%{version}.tar.gz
 # PATCH-FEATURE-UPSTREAM fix_numpy_matrix_warning_test.patch -- 
gh#scikit-image/scikit-image#3869
 Patch0:         fix_numpy_matrix_warning_test.patch
+# PATCH-Fix-UPSTREAM fix_numpy_1_17.patch -- gh#scikit-image/scikit-image#3992
+Patch1:         fix_numpy_1_17.patch
 BuildRequires:  %{python_module Cython >= 0.23.4}
 BuildRequires:  %{python_module devel}
 BuildRequires:  %{python_module numpy-devel >= 1.11}
@@ -70,7 +72,7 @@
 
 %prep
 %setup -q -n scikit-image-%{version}
-%patch0 -p1
+%autopatch -p1
 
 %build
 %python_build

++++++ fix_numpy_1_17.patch ++++++
>From cfeeda14f945e045d67790d176ff9cfc9afac0ff Mon Sep 17 00:00:00 2001
From: Juan Nunez-Iglesias <[email protected]>
Date: Sun, 7 Jul 2019 04:13:24 +1000
Subject: Update exposure for dask and np 1.17 compat

---
 skimage/exposure/exposure.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/skimage/exposure/exposure.py b/skimage/exposure/exposure.py
index 354e00ea15..caa87cb1e9 100644
--- a/skimage/exposure/exposure.py
+++ b/skimage/exposure/exposure.py
@@ -61,8 +61,8 @@
     if source_range not in ['image', 'dtype']:
         raise ValueError('Incorrect value for `source_range` argument: 
{}'.format(source_range))
     if source_range == 'image':
-        image_min = np.min(image).astype(np.int64)
-        image_max = np.max(image).astype(np.int64)
+        image_min = int(image.min().astype(np.int64))
+        image_max = int(image.max().astype(np.int64))
     elif source_range == 'dtype':
         image_min, image_max = dtype_limits(image, clip_negative=False)
     image, offset = _offset_array(image, image_min, image_max)

>From 6e560620fd1913e4953dff0e4a1cd4bf4ae04b37 Mon Sep 17 00:00:00 2001
From: Juan Nunez-Iglesias <[email protected]>
Date: Sun, 7 Jul 2019 07:27:42 -0500
Subject: Skip arraypad TypeError if mode not set in np 1.17+

---
 skimage/util/tests/test_arraypad.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/skimage/util/tests/test_arraypad.py 
b/skimage/util/tests/test_arraypad.py
index 73ddf4221c..b5b1cd92de 100644
--- a/skimage/util/tests/test_arraypad.py
+++ b/skimage/util/tests/test_arraypad.py
@@ -1,5 +1,7 @@
+from distutils.version import LooseVersion
 
 import numpy as np
+# note: skimage.util.pad is just numpy.pad
 from skimage.util import pad
 
 from skimage._shared import testing
@@ -989,6 +991,8 @@ def test_check_kwarg_not_allowed(self):
         with testing.raises(ValueError):
             pad(arr, 4, mode='mean', reflect_type='odd')
 
+    @testing.skipif(LooseVersion(np.__version__) >= LooseVersion('1.17'),
+                    reason='Error removed in NumPy 1.17')
     def test_mode_not_set(self):
         arr = np.arange(30).reshape(5, 6)
         with testing.raises(TypeError):

Reply via email to