guix_mirror_bot pushed a commit to branch master
in repository guix.
commit ad1941a08f31012d3de2099e8fb5f18df38b4afb
Author: Sharlatan Hellseher <[email protected]>
AuthorDate: Sat Sep 6 17:12:15 2025 +0100
gnu: python-tables: Update to 3.10.2.
* gnu/packages/python-xyz.scm (python-tables): Update to 3.10.2.
[build-system]: Switch to pyproject-build-system.
[phases]{set-LD_LIBRARY_PATH}: Replace by {pre-build} with setting up
environment variables for each library path which is available in
setup.py. Regenerate C code with Cython before build.
{pre-check}: New phase.
{check}: Rework test invocation to run just bare minimal test suite, add
a notes popping up during tests invocation describing it.
[native-inputs]: Add python-pytest, python-setuptools-next, and
python-sphinx.
[inputs]: Remove hdf5-1.10, and zlib; add bzip2, and hdf5.
Fixes: guix/guix#2342.
Change-Id: Ia1d00979123e459640d74a0dfd7fd52b25f8b9b7
---
gnu/packages/python-xyz.scm | 49 ++++++++++++++++++++++++++++++++++-----------
1 file changed, 37 insertions(+), 12 deletions(-)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 966693104a..98315dfb49 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -17809,18 +17809,20 @@ tasks, sockets, files, locks, and queues.")
(define-public python-tables
(package
(name "python-tables")
- (version "3.10.1")
+ (version "3.10.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "tables" version))
(sha256
(base32
- "1kr6y4qivqy462gva4bqym3x4alhxijfqjplxax3gh5r6k3pm82a"))
+ "0469jrkmp0qv8cmlqkizm3b8imyc97mk9pfn66ldpyl6f4m82i15"))
(snippet '(begin
(use-modules (guix build utils))
+ ;; TODO: Unbundle.
+ ;; (delete-file-recursively "hdf5-blosc")
(delete-file-recursively "c-blosc")))))
- (build-system python-build-system)
+ (build-system pyproject-build-system)
(arguments
(list
#:phases
@@ -17839,25 +17841,48 @@ tasks, sockets, files, locks, and queues.")
"\""
(search-input-file inputs "/lib/libblosc2.so")
"\",\n" m)))))
- (add-before 'build 'set-LD_LIBRARY_PATH
+ (add-before 'build 'pre-build
+ (lambda _
+ (invoke "make" "distclean") ;Regenerate C code with Cython
+ (setenv "BLOSC2_DIR" #$(this-package-input "cblosc2"))
+ (setenv "BLOSC_DIR" #$(this-package-input "c-blosc"))
+ (setenv "BZIP2_DIR" #$(this-package-input "bzip2"))
+ (setenv "HDF5_DIR" #$(this-package-input "hdf5"))
+ (setenv "LZO_DIR" #$(this-package-input "lzo"))))
+ (add-before 'check 'pre-check
(lambda _
- ;; The setup.py build system makes use of ctypes.CDLL, which
- ;; uses dlopen, which looks up library names from standard
- ;; locations or LD_LIBRARY_PATH.
- (setenv "LD_LIBRARY_PATH" (getenv "LIBRARY_PATH"))))
+ (setenv "HOME" "/tmp")))
(replace 'check
(lambda* (#:key tests? #:allow-other-keys)
(when tests?
- (invoke "python" "setup.py" "check")))))))
+ (with-directory-excursion "/tmp"
+ ;; Performing only a light (yet comprehensive) subset of the
+ ;; test suite. If you want a more complete test, try
+ ;; passing the --heavy flag to this script (or set the
+ ;; 'heavy' parameter in case you are using tables.test()
+ ;; call). The whole suite will take more than 4 hours to
+ ;; complete on a relatively modern CPU and around 512 MB of
+ ;; main memory.
+ (invoke "python" "-m" "tables.tests.test_all"))))))))
+ (native-inputs
+ (list pkg-config
+ python-cython
+ python-pytest
+ python-setuptools-next
+ python-sphinx))
+ (inputs
+ (list bzip2
+ c-blosc
+ c-blosc2
+ hdf5
+ lzo))
(propagated-inputs
(list python-blosc2
- python-numpy
python-numexpr
+ python-numpy
python-packaging
python-py-cpuinfo
python-typing-extensions))
- (native-inputs (list pkg-config python-cython))
- (inputs (list c-blosc c-blosc2 hdf5-1.10 bzip2 lzo zlib))
(home-page "https://www.pytables.org/")
(synopsis "Hierarchical datasets for Python")
(description "PyTables is a package for managing hierarchical datasets and