summaryrefslogtreecommitdiff
path: root/gnu/packages
diff options
context:
space:
mode:
authorSharlatan Hellseher <sharlatanus@gmail.com>2026-04-16 15:14:36 +0100
committerSharlatan Hellseher <sharlatanus@gmail.com>2026-08-09 13:01:05 +0100
commitd1c611f6dda078b75154faacdeb8dfe0d9ee3d8f (patch)
treeadfb204670655dcb30d5e92628bdff2095b908de /gnu/packages
parent95db21cca3f2e2b1d751e2bcda6759fdad7d8229 (diff)
gnu: python-h5py: Update to 3.16.0.
* gnu/packages/python-xyz.scm (python-h5py): Update to 3.16.0. [source]: Switch to git-fetch. [arguments] <test-flags>: Run all tests; provide option to test installed Python module. <phases>: Remove 'fix-hdf5-paths; use default 'check; add 'set-hdf5-options, and 'pre-check. [inputs]: Remove hdf5; add hdf5-parallel-openmpi. [native-inputs]: Add python-pytest-mpi. [propagated-inputs]: Add python-mpi4py. Fixes: guix/guix#7638 Merges: guix/guix!7946
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/python-xyz.scm53
1 files changed, 33 insertions, 20 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 4d1969f4b81..9fa2f1a9145 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -270,6 +270,7 @@
270 #:use-module (gnu packages maths) 270 #:use-module (gnu packages maths)
271 #:use-module (gnu packages messaging) 271 #:use-module (gnu packages messaging)
272 #:use-module (gnu packages monitoring) 272 #:use-module (gnu packages monitoring)
273 #:use-module (gnu packages mpi)
273 #:use-module (gnu packages multiprecision) 274 #:use-module (gnu packages multiprecision)
274 #:use-module (gnu packages ncurses) 275 #:use-module (gnu packages ncurses)
275 #:use-module (gnu packages networking) 276 #:use-module (gnu packages networking)
@@ -6440,46 +6441,58 @@ library.")
6440 (license license:bsd-3))) 6441 (license license:bsd-3)))
6441 6442
6442(define-public python-h5py 6443(define-public python-h5py
6444 ;; TODO: Move to (gnu packages python-science) or maths, prevent import mpi
6445 ;; module here.
6443 (package 6446 (package
6444 (name "python-h5py") 6447 (name "python-h5py")
6445 (version "3.15.1") 6448 (version "3.16.0")
6446 (source 6449 (source
6447 (origin 6450 (origin
6448 (method url-fetch) 6451 (method git-fetch)
6449 (uri (pypi-uri "h5py" version)) 6452 (uri (git-reference
6453 (url "https://github.com/h5py/h5py")
6454 (commit version)))
6455 (file-name (git-file-name name version))
6450 (sha256 6456 (sha256
6451 (base32 "0sbbw9100f2763czngbpg1jxisp5r5pkpa2swm6mcws4bka3wvn8")))) 6457 (base32 "1s5nqhylp7daizljnwr8bwwsxd92kqgz2106vi9q1c1q920ihsyy"))))
6452 (build-system pyproject-build-system) 6458 (build-system pyproject-build-system)
6453 (arguments 6459 (arguments
6454 (list 6460 (list
6455 ;; tests: 800 passed, 18 skipped, 4 deselected, 12 warnings 6461 ;; tests: 849 passed, 50 skipped
6456 #:test-flags 6462 #:test-flags
6457 ;; Tests requiring the build with MPI. 6463 #~(list "--pyargs" "h5py")
6458 #~(list "-k" (string-append "not test_mpio"
6459 " and not test_mpio_append"
6460 " and not test_mpi_atomic"
6461 " and not test_close_multiple_mpio_driver"))
6462 #:phases 6464 #:phases
6463 #~(modify-phases %standard-phases 6465 #~(modify-phases %standard-phases
6464 (add-after 'unpack 'fix-hdf5-paths 6466 (add-after 'unpack 'set-hdf5-options
6467 ;; For custom installation with Parallel HDF5 see:
6468 ;; <https://docs.h5py.org/en/latest/build.html#custom-installation>.
6465 (lambda _ 6469 (lambda _
6466 (setenv "HDF5_DIR" #$(this-package-input "hdf5")))) 6470 ;; XXX: Check if we need this:
6467 (replace 'check 6471 ;; <https://github.com/h5py/h5py/issues/2560>.
6468 (lambda* (#:key tests? test-flags #:allow-other-keys) 6472 ;; (setenv "H5PY_SETUP_REQUIRES" "0")
6469 (when tests? 6473 ;;
6470 (setenv "H5PY_TEST_CHECK_FILTERS" "1") 6474 ;; Project is part of h5py, but availalbe at
6471 (with-directory-excursion #$output 6475 ;; <https://oldhome.schmorp.de/marc/liblzf.html>, version 3.6
6472 (apply invoke "pytest" "-vv" test-flags)))))))) 6476 ;; was released on 2019.
6477 ;; (setenv "H5PY_SYSTEM_LZF" "1")
6478 (setenv "HDF5_DIR" #$(this-package-input "hdf5-parallel-openmpi"))
6479 (setenv "HDF5_MPI" "ON")))
6480 (add-before 'check 'pre-check
6481 (lambda _
6482 (setenv "H5PY_TEST_CHECK_FILTERS" "1")
6483 (delete-file-recursively "h5py"))))))
6473 (native-inputs 6484 (native-inputs
6474 (list pkg-config 6485 (list pkg-config
6475 python-cython 6486 python-cython
6476 python-pkgconfig 6487 python-pkgconfig
6477 python-pytest 6488 python-pytest
6489 python-pytest-mpi
6478 python-setuptools)) 6490 python-setuptools))
6479 (inputs 6491 (inputs
6480 (list hdf5)) 6492 (list hdf5-parallel-openmpi))
6481 (propagated-inputs 6493 (propagated-inputs
6482 (list python-numpy)) 6494 (list python-mpi4py
6495 python-numpy))
6483 (home-page "https://www.h5py.org/") 6496 (home-page "https://www.h5py.org/")
6484 (synopsis "Read and write HDF5 files from Python") 6497 (synopsis "Read and write HDF5 files from Python")
6485 (description 6498 (description