diff options
Diffstat (limited to 'dev-python/blosc/files/blosc-1.11.1-numpy-2.patch')
-rw-r--r-- | dev-python/blosc/files/blosc-1.11.1-numpy-2.patch | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/dev-python/blosc/files/blosc-1.11.1-numpy-2.patch b/dev-python/blosc/files/blosc-1.11.1-numpy-2.patch deleted file mode 100644 index 97010c0a4bf6..000000000000 --- a/dev-python/blosc/files/blosc-1.11.1-numpy-2.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 4823cb746023821166756322becd3fc242cd0b32 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> -Date: Sun, 16 Jun 2024 08:59:36 +0200 -Subject: [PATCH] Fix test failures with NumPy 2 - -* Replace deprecated `np.alltrue()` with `np.all()` (available since - NumPy 1.7.0). - -* Cast NumPy boolean to `bool()`, to ensure doctests pass both with - NumPy 2 (using `np.True_`) and NumPy 1 (using plain `True`). ---- - blosc/toplevel.py | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) - -diff --git a/blosc/toplevel.py b/blosc/toplevel.py -index ad9c12d..4d2d413 100644 ---- a/blosc/toplevel.py -+++ b/blosc/toplevel.py -@@ -514,7 +514,7 @@ def compress_ptr(address, items, typesize=8, clevel=9, shuffle=blosc.SHUFFLE, - items, np_array.dtype.itemsize) - >>> d = blosc.decompress(c) - >>> np_ans = numpy.fromstring(d, dtype=np_array.dtype) -- >>> (np_array == np_ans).all() -+ >>> bool((np_array == np_ans).all()) - True - - >>> import ctypes -@@ -640,7 +640,7 @@ def decompress_ptr(bytes_like, address): - items, np_array.dtype.itemsize) - >>> np_ans = numpy.empty(items, dtype=np_array.dtype) - >>> nbytes = blosc.decompress_ptr(c, np_ans.__array_interface__['data'][0]) -- >>> (np_array == np_ans).all() -+ >>> bool((np_array == np_ans).all()) - True - >>> nbytes == items * np_array.dtype.itemsize - True -@@ -769,12 +769,12 @@ def unpack_array(packed_array, **kwargs): - >>> len(parray) < a.size*a.itemsize - True - >>> a2 = blosc.unpack_array(parray) -- >>> numpy.alltrue(a == a2) -+ >>> bool(numpy.all(a == a2)) - True - >>> a = numpy.array(['å', 'ç', 'ø']) - >>> parray = blosc.pack_array(a) - >>> a2 = blosc.unpack_array(parray) -- >>> numpy.alltrue(a == a2) -+ >>> bool(numpy.all(a == a2)) - True - """ - |