#2 Update to 3.5.1 (#1687831)
Merged 24 days ago by zbyszek. Opened 24 days ago by churchyard.
rpms/ churchyard/python-tables 3.5.1  into  master

@@ -1,109 +0,0 @@ 

- From 1aa6d88c6d16d2e93629e2a5a607a7757fcf7f94 Mon Sep 17 00:00:00 2001

- From: Antonio Valentino <antonio.valentino@tiscali.it>

- Date: Wed, 2 Jan 2019 17:11:09 +0000

- Subject: [PATCH] Fix future warnings

- 

- ---

-  tables/array.py             | 4 ++--

-  tables/scripts/ptrepack.py  | 9 ++++++---

-  tables/tests/test_array.py  | 2 ++

-  tables/tests/test_earray.py | 2 +-

-  tables/tests/test_numpy.py  | 3 ++-

-  5 files changed, 13 insertions(+), 7 deletions(-)

- 

- diff --git a/tables/array.py b/tables/array.py

- index 85f07b33..d3d1e06e 100644

- --- a/tables/array.py

- +++ b/tables/array.py

- @@ -801,7 +801,7 @@ def _read_selection(self, selection, reorder, shape):

-              k[idx] = neworder.argsort()

-              # Apparently, a copy is not needed here, but doing it

-              # for symmetry with the `_write_selection()` method.

- -            nparr = nparr[k].copy()

- +            nparr = nparr[tuple(k)].copy()

-          return nparr

-  

-      def _write_slice(self, startl, stopl, stepl, shape, nparr):

- @@ -833,7 +833,7 @@ def _write_selection(self, selection, reorder, shape, nparr):

-              k[idx] = neworder

-              # For a reason a don't understand well, we need a copy of

-              # the reordered array

- -            nparr = nparr[k].copy()

- +            nparr = nparr[tuple(k)].copy()

-          self._g_write_selection(selection, nparr)

-  

-      def _read(self, start, stop, step, out=None):

- diff --git a/tables/scripts/ptrepack.py b/tables/scripts/ptrepack.py

- index 796c4a46..7953197e 100644

- --- a/tables/scripts/ptrepack.py

- +++ b/tables/scripts/ptrepack.py

- @@ -23,7 +23,10 @@

-  import os.path

-  import argparse

-  import warnings

- -

- +try:

- +    from time import process_time as cputime

- +except ImportError:

- +    from time import clock as cputime

-  

-  from tables.file import open_file

-  from tables.group import Group

- @@ -492,7 +495,7 @@ def main():

-  

-      # Some timing

-      t1 = time.time()

- -    cpu1 = time.clock()

- +    cpu1 = cputime()

-      # Copy the file

-      if verbose:

-          print("+=+" * 20)

- @@ -541,7 +544,7 @@ def main():

-  

-      # Gather some statistics

-      t2 = time.time()

- -    cpu2 = time.clock()

- +    cpu2 = cputime ()

-      tcopy = round(t2 - t1, 3)

-      cpucopy = round(cpu2 - cpu1, 3)

-      try:

- diff --git a/tables/tests/test_array.py b/tables/tests/test_array.py

- index 34f82e32..72c39aa6 100644

- --- a/tables/tests/test_array.py

- +++ b/tables/tests/test_array.py

- @@ -2084,6 +2084,8 @@ def test01d_read(self):

-          tbarr = self.tbarr

-  

-          for key in self.working_keyset:

- +            if nparr.ndim > 1:

- +                key = tuple(key)

-              if common.verbose:

-                  print("Selection to test:", key)

-              a = nparr[key]

- diff --git a/tables/tests/test_earray.py b/tables/tests/test_earray.py

- index a9256af1..865c49db 100644

- --- a/tables/tests/test_earray.py

- +++ b/tables/tests/test_earray.py

- @@ -482,7 +482,7 @@ def test03_readEArray_out_argument(self):

-              slice_obj = [slice(None)] * len(earray.shape)

-              #slice_obj[earray.maindim] = slice(self.start, stop, self.step)

-              slice_obj[earray.maindim] = slice(self.start, self.stop, self.step)

- -            row = row[slice_obj].copy()

- +            row = row[tuple(slice_obj)].copy()

-              earray.read(self.start, self.stop, self.step, out=row)

-          except IndexError:

-              row = numpy.empty(shape=self.shape, dtype=self.dtype)

- diff --git a/tables/tests/test_numpy.py b/tables/tests/test_numpy.py

- index 6e453337..ce2d7068 100644

- --- a/tables/tests/test_numpy.py

- +++ b/tables/tests/test_numpy.py

- @@ -465,7 +465,8 @@ def test01_readTableNum(self):

-          for colname in table.colnames:

-              numcol = table.read(field=colname)

-              typecol = table.coltypes[colname]

- -            nctypecode = np.typeNA[numcol.dtype.char[0]]

- +            #nctypecode = np.typeNA[numcol.dtype.char[0]]

- +            nctypecode = np.sctypeDict[numcol.dtype.char[0]]

-              if typecol != "string":

-                  if common.verbose:

-                      print("Typecode of NumPy column read:", nctypecode)

@@ -1,44 +0,0 @@ 

- From 46fa2f07c00613ed6b647b2cf44e388f547fe668 Mon Sep 17 00:00:00 2001

- From: Antonio Valentino <antonio.valentino@tiscali.it>

- Date: Tue, 1 Jan 2019 12:31:34 +0100

- Subject: [PATCH] Check for the correct exception types (numpy 1.16 compat)

- 

- ---

-  tables/tests/test_array.py | 2 +-

-  tables/tests/test_lists.py | 4 ++--

-  2 files changed, 3 insertions(+), 3 deletions(-)

- 

- diff --git a/tables/tests/test_array.py b/tables/tests/test_array.py

- index b7d6a3f5..563c7662 100644

- --- a/tables/tests/test_array.py

- +++ b/tables/tests/test_array.py

- @@ -2005,7 +2005,7 @@ def test(self):

-          """Test for creation of non-homogeneous arrays."""

-  

-          # This checks ticket #12.

- -        self.assertRaises(ValueError,

- +        self.assertRaises((ValueError, TypeError),

-                            self.h5file.create_array, '/', 'test', [1, [2, 3]])

-          self.assertRaises(NoSuchNodeError, self.h5file.remove_node, '/test')

-  

- diff --git a/tables/tests/test_lists.py b/tables/tests/test_lists.py

- index 9cf83fec..9e79130a 100644

- --- a/tables/tests/test_lists.py

- +++ b/tables/tests/test_lists.py

- @@ -144,14 +144,14 @@ def test00_char(self):

-              print('\n', '-=' * 30)

-              print("Running test for %s" % (self.title))

-          a = self.charList

- -        with self.assertRaises(ValueError):

- +        with self.assertRaises((ValueError, TypeError)):

-              WriteRead(self.h5fname, a)

-  

-      def test01_types(self):

-          """Non supported lists object (numerical types)"""

-  

-          a = self.numericalList

- -        with self.assertRaises(ValueError):

- +        with self.assertRaises((ValueError, TypeError)):

-              WriteRead(self.h5fname, a)

-  

-  

@@ -1,34 +0,0 @@ 

- From f6b64c942fb91e6c261fa455969a38482c22beeb Mon Sep 17 00:00:00 2001

- From: Antonio Valentino <antonio.valentino@tiscali.it>

- Date: Tue, 1 Jan 2019 12:25:43 +0100

- Subject: [PATCH] Fix issue with not writeable buffer (numpy 1.16 compat)

- 

- ---

-  tables/hdf5extension.pyx | 7 +++++--

-  1 file changed, 5 insertions(+), 2 deletions(-)

- 

- diff --git a/tables/hdf5extension.pyx b/tables/hdf5extension.pyx

- index 6dc32f48..e64d1a1b 100644

- --- a/tables/hdf5extension.pyx

- +++ b/tables/hdf5extension.pyx

- @@ -111,6 +111,9 @@ from utilsextension cimport malloc_dims, get_native_type, cstr_to_pystr, load_re

-  

-  #-------------------------------------------------------------------

-  

- +cdef extern from "Python.h":

- +

- +    object PyByteArray_FromStringAndSize(char *s, Py_ssize_t len)

-  

-  # Functions from HDF5 ARRAY (this is not part of HDF5 HL; it's private)

-  cdef extern from "H5ARRAY.h" nogil:

- @@ -2141,8 +2144,8 @@ cdef class VLArray(Leaf):

-          # Create a buffer to keep this info. It is important to do a

-          # copy, because we will dispose the buffer memory later on by

-          # calling the H5Dvlen_reclaim. PyBytes_FromStringAndSize does this.

- -        buf = PyBytes_FromStringAndSize(<char *>rdata[i].p,

- -                                        vllen*self._atomicsize)

- +        buf = PyByteArray_FromStringAndSize(<char *>rdata[i].p,

- +                                            vllen*self._atomicsize)

-        else:

-          # Case where there is info with zero lentgh

-          buf = None

file modified
+11 -12

@@ -6,8 +6,8 @@ 

  

  Summary:        HDF5 support in Python

  Name:           python-tables

- Version:        3.4.4

- Release:        5%{?dist}%{?gitcommit:.git%{shortcommit}}

+ Version:        3.5.1

+ Release:        1%{?dist}%{?gitcommit:.git%{shortcommit}}

  #Source0:        https://github.com/PyTables/PyTables/archive/%{commit}/PyTables-%{commit}.tar.gz

  Source0:        https://github.com/PyTables/PyTables/archive/v%{version}/python-tables-%{version}.tar.gz

  

@@ -17,17 +17,12 @@ 

  Source1:        https://github.com/PyTables/PyTables/releases/download/v%{manual_version}/pytablesmanual-%{manual_version}.pdf

  Patch0:         always-use-blosc.diff

  

- Patch1:         https://github.com/PyTables/PyTables/commit/f6b64c942fb91e6c261fa455969a38482c22beeb.patch

- Patch2:         https://github.com/PyTables/PyTables/commit/46fa2f07c00613ed6b647b2cf44e388f547fe668.patch

- Patch3:         https://github.com/PyTables/PyTables/commit/1aa6d88c6d16d2e93629e2a5a607a7757fcf7f94.patch

- 

  License:        BSD

  URL:            http://www.pytables.org

  

  BuildRequires:  hdf5-devel >= 1.8

  BuildRequires:  bzip2-devel

  BuildRequires:  lzo-devel

- BuildRequires:  python2-Cython >= 0.13

  BuildRequires:  python2-numpy

  BuildRequires:  python2-numexpr >= 2.4

  BuildRequires:  blosc-devel >= 1.5.2

@@ -90,8 +85,9 @@ 

  find c-blosc -mindepth 1 -maxdepth 1 -name hdf5 -prune -o -exec rm -r {} +

  

  %build

- %py2_build

+ # Python 3 first not to depend on python2-Cython

  %py3_build

+ %py2_build

  

  %install

  chmod -x examples/check_examples.sh

@@ -110,8 +106,8 @@ 

  

  %files -n python2-tables

  %license LICENSE.txt LICENSES

- %{python2_sitearch}/tables

- %{python2_sitearch}/tables-%{version}*.egg-info

+ %{python2_sitearch}/tables/

+ %{python2_sitearch}/tables-%{version}*.egg-info/

  

  %files -n python%{python3_pkgversion}-tables

  %license LICENSE.txt LICENSES

@@ -119,8 +115,8 @@ 

  %{_bindir}/ptrepack

  %{_bindir}/pt2to3

  %{_bindir}/pttree

- %{python3_sitearch}/tables

- %{python3_sitearch}/tables-%{version}*.egg-info

+ %{python3_sitearch}/tables/

+ %{python3_sitearch}/tables-%{version}*.egg-info/

  

  %files doc

  %license LICENSE.txt LICENSES

@@ -129,6 +125,9 @@ 

  %doc examples/

  

  %changelog

+ * Wed May 22 2019 Miro Hrončok <mhroncok@redhat.com> - 3.5.1-1

+ - Update to 3.5.1 (#1687831)

+ 

  * Sat Mar 16 2019 Orion Poplawski <orion@nwra.com> - 3.4.4-5

  - Rebuild for hdf5 1.10.5

  

file modified
+1 -1

@@ -1,2 +1,2 @@ 

  SHA512 (pytablesmanual-3.3.0.pdf) = beb068a301e20370fdab9f942bed271b94872f409087cba8f7127967a51e45a233d8e6df1aaa12aad532282aec324b0c823b1646be31a5b71e5e7c035ba06270

- SHA512 (python-tables-3.4.4.tar.gz) = c8f9413a07a08169876b60347e837902a888b43a6e85193a5fd0b0d47af8ca55ea596e9a49cdcb69baad1d6e284cd529aebd1894017b9cf6282fdf7f09f20fcb

+ SHA512 (python-tables-3.5.1.tar.gz) = ffbfb058280f115dbab1e91301573197edb08567203a1bfcf329c0871ed164c9a185a56f8218b0071af8e72ea133d28973a4ea3110e437e10a32bc553e481cd0

no initial comment

Pull-Request has been merged by zbyszek

24 days ago

s390x failed:

BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test00_version (tables.tests.test_index_backcompat.Indexes2_0TestCase)
BUILDSTDERR: Checking index version.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test01_string (tables.tests.test_index_backcompat.Indexes2_0TestCase)
BUILDSTDERR: Checking string indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test02_bool (tables.tests.test_index_backcompat.Indexes2_0TestCase)
BUILDSTDERR: Checking bool indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test03_int (tables.tests.test_index_backcompat.Indexes2_0TestCase)
BUILDSTDERR: Checking int indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test04_float (tables.tests.test_index_backcompat.Indexes2_0TestCase)
BUILDSTDERR: Checking float indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test00_version (tables.tests.test_index_backcompat.Indexes2_1TestCase)
BUILDSTDERR: Checking index version.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test01_string (tables.tests.test_index_backcompat.Indexes2_1TestCase)
BUILDSTDERR: Checking string indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test02_bool (tables.tests.test_index_backcompat.Indexes2_1TestCase)
BUILDSTDERR: Checking bool indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test03_int (tables.tests.test_index_backcompat.Indexes2_1TestCase)
BUILDSTDERR: Checking int indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ======================================================================
BUILDSTDERR: ERROR: test04_float (tables.tests.test_index_backcompat.Indexes2_1TestCase)
BUILDSTDERR: Checking float indexes.
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Traceback (most recent call last):
BUILDSTDERR:   File "/builddir/build/BUILDROOT/python-tables-3.5.1-1.fc31.s390x/usr/lib64/python2.7/site-packages/tables/tests/test_index_backcompat.py", line 21, in setUp
BUILDSTDERR:     self.sl = self.table1.cols.var1.index.slicesize
BUILDSTDERR: AttributeError: 'UnImplemented' object has no attribute 'cols'
BUILDSTDERR: ----------------------------------------------------------------------
BUILDSTDERR: Ran 6385 tests in 122.441s
BUILDSTDERR: FAILED (errors=10, skipped=27)