[PATCH 0/5] gnu: python-vedo: Update to 2022.2.0 and sanity-check failures.

  • Done
  • quality assurance status badge
Details
4 participants
  • Liliana Marie Prikler
  • Ludovic Courtès
  • Maxime Devos
  • Paul A. Patience
Owner
unassigned
Submitted by
Paul A. Patience
Severity
normal
Merged with
P
P
Paul A. Patience wrote on 12 Apr 2022 03:21
(address . guix-patches@gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220412012143.30573-1-paul@apatience.com
Hello,

The following patch series updates python-vedo to its latest version,
and also adds support for the #:tests? flag to fenics-dolfin, fenics and
python-vedo.

Unfortunately, I can't get fenics or python-vedo to build except by
deleting the sanity-check phase, and this even before applying any of my
patches.
(I've confirmed that my patches are correct by testing the builds
without sanity-checks, so applying them shouldn't be an issue.)

The following is the sanity-check error obtained when building fenics:

starting phase `sanity-check'
validating 'fenics-dolfin' /gnu/store/lkb8mx8dk82znkzfgnx1k1mklaj9b34d-fenics-2019.1.0.post0/lib/python3.9/site-packages
...checking requirements: ERROR: fenics-dolfin==2019.1.0 ContextualVersionConflict(pybind11 2.8.1 (/gnu/store/qmxw9dqqywrlllzlidv09f2nazirjwk7-pybind11-2.8.1/lib/python3.9/site-packages), Requirement.parse('pybind11==2.2.4'), {'fenics-dolfin'})
error: in phase 'sanity-check': uncaught exception:
%exception #<&invoke-error program: "python" arguments: ("/gnu/store/35ix1m6m8a5s21j02ajhdyqxb2xkshfb-sanity-check.py" "/gnu/store/lkb8mx8dk82znkzfgnx1k1mklaj9b34d-fenics-2019.1.0.post0/lib/python3.9/site-packages") exit-status: 1 term-signal: #f stop-signal: #f>
phase `sanity-check' failed after 0.2 seconds

Note that it complains that pybind11 is not at version 2.2.4, but when
fenics was last updated (in commit 37bb0d1eafb3f08a204aed8c928cbf7cbc69cd19),
the version of pybind11 at the time was 2.3.0, so this would appear to
be either a new issue, or an issue specific to my machine (foreign distro).

The sanity-check errors from vedo are similarly bizarre -- they complain
about a missing vtk, but it is there in the propagated inputs.

With old version of python-vedo:

starting phase `sanity-check'
validating 'vedo' /gnu/store/4h10widg2y0nhvacz8mricn187qzw9dq-python-vedo-2021.0.3/lib/python3.9/site-packages
...checking requirements: ERROR: vedo==2021.0.3 DistributionNotFound(Requirement.parse('vtk'), {'vedo'})
error: in phase 'sanity-check': uncaught exception:
%exception #<&invoke-error program: "python" arguments: ("/gnu/store/35ix1m6m8a5s21j02ajhdyqxb2xkshfb-sanity-check.py" "/gnu/store/4h10widg2y0nhvacz8mricn187qzw9dq-python-vedo-2021.0.3/lib/python3.9/site-packages") exit-status: 1 term-signal: #f stop-signal: #f>
phase `sanity-check' failed after 0.2 seconds

With updated version of python-vedo (i.e., including the
python-deprecated propagated input):

starting phase `sanity-check'
validating 'vedo' /gnu/store/a6g20gkvi1l70arh2rm53x7gm30dzqcp-python-vedo-2022.2.0/lib/python3.9/site-packages
...checking requirements: ERROR: vedo==2022.2.0 DistributionNotFound(Requirement.parse('vtk<9.1.0'), {'vedo'})
error: in phase 'sanity-check': uncaught exception:
%exception #<&invoke-error program: "python" arguments: ("/gnu/store/35ix1m6m8a5s21j02ajhdyqxb2xkshfb-sanity-check.py" "/gnu/store/a6g20gkvi1l70arh2rm53x7gm30dzqcp-python-vedo-2022.2.0/lib/python3.9/site-packages") exit-status: 1 term-signal: #f stop-signal: #f>
phase `sanity-check' failed after 0.2 seconds

The latest commit of fenics (there isn't a newer release than the one
included in Guix) no longer requires a specific version of pybind11 [1],
and in addition, it seems the focus is on the dolfinx project [2] rather
than dolfin (dolfin is already considered legacy [3]), so perhaps it
would be worth updating the fenics package to the latest git commit.

That wouldn't solve the problem python-vedo's sanity-check is
encountering, though.

Any help would be appreciated.

Best regards,
Paul


Paul A. Patience (5):
gnu: fenics-dolfin: Honor #:tests? flag.
gnu: fenics: Honor #:tests? flag.
gnu: python-vedo: Honor #:tests? flag.
gnu: python-vedo: Remove input labels.
gnu: python-vedo: Update to 2022.2.0.

gnu/packages/python-science.scm | 35 ++++++++++++++++----------------
gnu/packages/simulation.scm | 36 +++++++++++++++++----------------
2 files changed, 37 insertions(+), 34 deletions(-)

--
2.35.1
L
L
Liliana Marie Prikler wrote on 12 Apr 2022 08:00
(address . control@debbugs.gnu.org)
dbe14dee126fadb922662ce8d2a6695ac1c4f901.camel@ist.tugraz.at
merge 54869 54870 54871 54872 54873 54874
thanks
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-1-paul@apatience.com
I've fixed the sanity check issues in this patch series, along with some other
minor things (particularly in the python-vedo package).

There is still one problem, though, but it has been present (for me) since
before any of these patches: one of the fenics tests around 24 % of the test
suite hangs.
I have to build it with --without-tests=fenics, but since it was present since
before, I haven't disabled the tests in the fenics package.

Oh, also, I tried to remove the input labels from fenics-dolfin, but ran into
build errors (failing to find catch.cpp).

Paul A. Patience (7):
gnu: fenics-dolfin: Honor #:tests? flag.
gnu: fenics: Honor #:tests? flag.
gnu: fenics: Fix sanity check.
gnu: python-vedo: Honor #:tests? flag.
gnu: python-vedo: Remove input labels.
gnu: python-vedo: Disable sanity check.
gnu: python-vedo: Update to 2022.2.0.

gnu/packages/python-science.scm | 57 ++++++++++++++++++++-------------
gnu/packages/simulation.scm | 40 +++++++++++++----------
2 files changed, 58 insertions(+), 39 deletions(-)

--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 1/7] gnu: fenics-dolfin: Honor #:tests? flag.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-2-paul@apatience.com
* gnu/packages/simulation.scm (fenics-dolfin)[arguments]: Adjust custom
'check' phase to honor the #:tests? flag.
---
gnu/packages/simulation.scm | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)

Toggle diff (24 lines)
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index 3f2d8e136d..aebb6be15e 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -549,12 +549,13 @@ (define-public fenics-dolfin
")\n") port)))
#t))
(replace 'check
- (lambda _
- (and (invoke "make" "unittests")
- (invoke "make" "demos")
- (invoke "ctest" "-R" "unittests")
- (invoke "ctest" "-R" "demo" "-R" "serial")
- (invoke "ctest" "-R" "demo" "-R" "mpi")))))))
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (and (invoke "make" "unittests")
+ (invoke "make" "demos")
+ (invoke "ctest" "-R" "unittests")
+ (invoke "ctest" "-R" "demo" "-R" "serial")
+ (invoke "ctest" "-R" "demo" "-R" "mpi"))))))))
(home-page "https://bitbucket.org/fenics-project/dolfin/")
(synopsis "Problem solving environment for differential equations")
(description
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 2/7] gnu: fenics: Honor #:tests? flag.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-3-paul@apatience.com
* gnu/packages/simulation.scm (fenics)[arguments]: Adjust custom 'check'
phase to honor the #:tests? flag.
---
gnu/packages/simulation.scm | 23 ++++++++++++-----------
1 file changed, 12 insertions(+), 11 deletions(-)

Toggle diff (34 lines)
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index aebb6be15e..3260841608 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -660,17 +660,18 @@ (define-public fenics
;; Restrict OpenBLAS to MPI-only in preference to MPI+OpenMP.
(setenv "OPENBLAS_NUM_THREADS" "1")))
(replace 'check
- (lambda _
- (with-directory-excursion "test"
- ;; Note: The test test_snes_set_from_options() in the file
- ;; unit/nls/test_PETScSNES_solver.py fails and is ignored.
- ;; Limit the number of jobs to 3 as 500 MiB of memory is used
- ;; per process.
- (invoke "mpirun" "-np" (number->string
- (min 3 (parallel-job-count)))
- "python" "-B" "-m"
- "pytest" "unit" "--ignore"
- "unit/nls/test_PETScSNES_solver.py"))))
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (with-directory-excursion "test"
+ ;; Note: The test test_snes_set_from_options() in the file
+ ;; unit/nls/test_PETScSNES_solver.py fails and is ignored.
+ ;; Limit the number of jobs to 3 as 500 MiB of memory is used
+ ;; per process.
+ (invoke "mpirun" "-np" (number->string
+ (min 3 (parallel-job-count)))
+ "python" "-B" "-m"
+ "pytest" "unit" "--ignore"
+ "unit/nls/test_PETScSNES_solver.py")))))
(add-after 'install 'install-demo-files
(lambda* (#:key outputs #:allow-other-keys)
(let* ((demos (string-append
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 3/7] gnu: fenics: Fix sanity check.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-4-paul@apatience.com
* gnu/packages/simulation.scm (fenics)[arguments]: Relax pybind11
requirement to appease the sanity check.
---
gnu/packages/simulation.scm | 4 ++++
1 file changed, 4 insertions(+)

Toggle diff (15 lines)
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index 3260841608..b0f6046022 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -610,6 +610,10 @@ (define-public fenics
(arguments
`(#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'relax-requirements
+ (lambda _
+ (substitute* "python/setup.py"
+ (("pybind11==") "pybind11>="))))
(add-after 'patch-source-shebangs 'set-paths
(lambda _
;; Define paths to store locations.
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 4/7] gnu: python-vedo: Honor #:tests? flag.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-5-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo)[arguments]: Adjust
custom 'check' phase to honor the #:tests? flag. Also remove its
trailing boolean.
---
gnu/packages/python-science.scm | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)

Toggle diff (29 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 07d713e013..4538904b68 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -876,15 +876,15 @@ (define-public python-vedo
(add-after 'build 'mpi-setup
,%openmpi-setup)
(replace 'check
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (setenv "HOME" (getcwd))
- (add-installed-pythonpath inputs outputs)
- (with-directory-excursion "tests"
- (for-each (lambda (dir)
- (with-directory-excursion dir
- (invoke "./run_all.sh")))
- '("common" "dolfin")))
- #t)))))
+ (lambda* (#:key tests? inputs outputs #:allow-other-keys)
+ (when tests?
+ (setenv "HOME" (getcwd))
+ (add-installed-pythonpath inputs outputs)
+ (with-directory-excursion "tests"
+ (for-each (lambda (dir)
+ (with-directory-excursion dir
+ (invoke "./run_all.sh")))
+ '("common" "dolfin")))))))))
(inputs ; for the check phase
`(("dolfin" ,fenics)
("pkgconfig" ,python-pkgconfig)
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 6/7] gnu: python-vedo: Disable sanity check.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-7-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo)[arguments]: Disable
sanity check.
---
gnu/packages/python-science.scm | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)

Toggle diff (19 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 3afaa0efc2..d0fca49aaf 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -884,7 +884,13 @@ (define-public python-vedo
(for-each (lambda (dir)
(with-directory-excursion dir
(invoke "./run_all.sh")))
- '("common" "dolfin")))))))))
+ '("common" "dolfin"))))))
+ ;; Disable the sanity check, which fails with the following error:
+ ;;
+ ;; ...checking requirements: ERROR: vedo==2021.0.3 DistributionNotFound(Requirement.parse('vtk'), {'vedo'})
+ ;;
+ ;; Probably it cannot find VTK because it isn't a Python library.
+ (delete 'sanity-check))))
(inputs ; for the check phase
(list fenics
python-matplotlib
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 5/7] gnu: python-vedo: Remove input labels.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-6-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo)[inputs]: Remove labels
and sort the inputs.
[propagated-inputs]: Remove labels.
---
gnu/packages/python-science.scm | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)

Toggle diff (24 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 4538904b68..3afaa0efc2 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -886,14 +886,14 @@ (define-public python-vedo
(invoke "./run_all.sh")))
'("common" "dolfin")))))))))
(inputs ; for the check phase
- `(("dolfin" ,fenics)
- ("pkgconfig" ,python-pkgconfig)
- ("matplotlib" ,python-matplotlib)))
+ (list fenics
+ python-matplotlib
+ python-pkgconfig))
(native-inputs ; for python-pkgconfig
(list pkg-config))
(propagated-inputs
- `(("numpy" ,python-numpy)
- ("vtk" ,vtk)))
+ (list python-numpy
+ vtk))
(home-page "https://github.com/marcomusy/vedo")
(synopsis
"Analysis and visualization of 3D objects and point clouds")
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 13:53
[PATCH v2 7/7] gnu: python-vedo: Update to 2022.2.0.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422115258.63649-8-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo): Update to 2022.2.0.
[arguments]: Add 'fix-tests' phase.
[inputs]: Move fenics and python-matplotlib to propagated-inputs.
Move python-pkgconfig from here...
[native-inputs]: ...to here.
[propagated-inputs]: Add python-deprecated (and fenics and
python-matplotlib).
[description]: Make description more accurate.
---
gnu/packages/python-science.scm | 31 +++++++++++++++++++------------
1 file changed, 19 insertions(+), 12 deletions(-)

Toggle diff (80 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index d0fca49aaf..b1fc94cecc 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -17,6 +17,7 @@
;;; Copyright © 2021 Felix Gruber <felgru@posteo.net>
;;; Copyright © 2022 Malte Frank Gerdes <malte.f.gerdes@gmail.com>
;;; Copyright © 2022 Guillaume Le Vaillant <glv@posteo.net>
+;;; Copyright © 2022 Paul A. Patience <paul@apatience.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -858,21 +859,28 @@ (define-public python-upsetplot
(define-public python-vedo
(package
(name "python-vedo")
- (version "2021.0.3")
+ (version "2022.2.0")
(source
(origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/marcomusy/vedo")
- (commit version)))
+ (commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
- "18i3ajh5jzhpc86di15lwh4jv97jhm627ii877sa4yhv6abzjfpn"))))
+ "1hhv4xc4bphhd1zrnf7r6fpf65xvkdqmb1lh51qg1xpv91h2az0h"))))
(build-system python-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'fix-tests
+ ;; These tests require online data.
+ (lambda _
+ (substitute* "tests/common/test_actors.py"
+ (("^st = .*") "")
+ (("^assert isinstance\\(st\\.GetTexture\\(\\), .*") ""))
+ (delete-file "tests/common/test_pyplot.py")))
(add-after 'build 'mpi-setup
,%openmpi-setup)
(replace 'check
@@ -887,18 +895,18 @@ (define-public python-vedo
'("common" "dolfin"))))))
;; Disable the sanity check, which fails with the following error:
;;
- ;; ...checking requirements: ERROR: vedo==2021.0.3 DistributionNotFound(Requirement.parse('vtk'), {'vedo'})
+ ;; ...checking requirements: ERROR: vedo==2022.2.0 DistributionNotFound(Requirement.parse('vtk<9.1.0'), {'vedo'})
;;
;; Probably it cannot find VTK because it isn't a Python library.
(delete 'sanity-check))))
- (inputs ; for the check phase
- (list fenics
- python-matplotlib
+ (native-inputs
+ (list pkg-config
python-pkgconfig))
- (native-inputs ; for python-pkgconfig
- (list pkg-config))
(propagated-inputs
- (list python-numpy
+ (list fenics
+ python-deprecated
+ python-matplotlib
+ python-numpy
vtk))
(home-page "https://github.com/marcomusy/vedo")
(synopsis
@@ -909,8 +917,7 @@ (define-public python-vedo
range of functionalities for working with three-dimensional meshes and
point clouds. It can also be used to generate high quality
two-dimensional renderings such as scatter plots and histograms.
-@code{vedo} is based on @code{vtk} and @code{numpy}, with no other
-dependencies.")
+@code{vedo} is based on @code{vtk} and @code{numpy}.")
;; vedo is released under the Expat license. Included fonts are
;; covered by the OFL license and textures by the CC0 license.
;; The earth images are in the public domain.
--
2.35.1
M
M
Maxime Devos wrote on 22 Apr 2022 19:46
Re: [bug#54869] [PATCH v2 1/7] gnu: fenics-dolfin: Honor #:tests? flag.
c2de0c46a9390022ede738ad93fe05b1b00faa4c.camel@telenet.be
Paul A. Patience schreef op vr 22-04-2022 om 11:53 [+0000]:
Toggle quote (9 lines)
> -                  (invoke "ctest" "-R" "demo" "-R" "mpi")))))))
> +           (lambda* (#:key tests? #:allow-other-keys)
> +             (when tests?
> +               (and (invoke "make" "unittests")
> +                    (invoke "make" "demos")
> +                    (invoke "ctest" "-R" "unittests")
> +                    (invoke "ctest" "-R" "demo" "-R" "serial")
> +                    (invoke "ctest" "-R" "demo" "-R" "mpi"))))))))

The 'and' is pointless, it can be removed --- IIUC, 'invoke' throws
exceptions, it doesn't return #false. Anyway, honouring #:tests? is
nice (for cross-compilation and --without-tests=...).

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYmLqDBccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7kIzAQDYXL4oMKHDy6UmUD9Jy5HVQNer
g6grMLZZ/s6/CvcxpAEA6ZFizpKtgtBF+NEolLnhiJvDd2K+ZLvGCBbVllCEFAU=
=EAyi
-----END PGP SIGNATURE-----


P
P
Paul A. Patience wrote on 22 Apr 2022 22:25
[PATCH v3 2/7] gnu: fenics: Honor #:tests? flag.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-3-paul@apatience.com
* gnu/packages/simulation.scm (fenics)[arguments]: Adjust custom 'check'
phase to honor the #:tests? flag.
---
gnu/packages/simulation.scm | 23 ++++++++++++-----------
1 file changed, 12 insertions(+), 11 deletions(-)

Toggle diff (34 lines)
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index 757738e627..230ae62826 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -657,17 +657,18 @@ (define-public fenics
;; Restrict OpenBLAS to MPI-only in preference to MPI+OpenMP.
(setenv "OPENBLAS_NUM_THREADS" "1")))
(replace 'check
- (lambda _
- (with-directory-excursion "test"
- ;; Note: The test test_snes_set_from_options() in the file
- ;; unit/nls/test_PETScSNES_solver.py fails and is ignored.
- ;; Limit the number of jobs to 3 as 500 MiB of memory is used
- ;; per process.
- (invoke "mpirun" "-np" (number->string
- (min 3 (parallel-job-count)))
- "python" "-B" "-m"
- "pytest" "unit" "--ignore"
- "unit/nls/test_PETScSNES_solver.py"))))
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (with-directory-excursion "test"
+ ;; Note: The test test_snes_set_from_options() in the file
+ ;; unit/nls/test_PETScSNES_solver.py fails and is ignored.
+ ;; Limit the number of jobs to 3 as 500 MiB of memory is used
+ ;; per process.
+ (invoke "mpirun" "-np" (number->string
+ (min 3 (parallel-job-count)))
+ "python" "-B" "-m"
+ "pytest" "unit" "--ignore"
+ "unit/nls/test_PETScSNES_solver.py")))))
(add-after 'install 'install-demo-files
(lambda* (#:key outputs #:allow-other-keys)
(let* ((demos (string-append
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:25
[PATCH v3 0/7] gnu: python-vedo: Update to 2022.2.0.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-1-paul@apatience.com
I've integrated the suggestions of Maxime Devos.

Paul A. Patience (7):
gnu: fenics-dolfin: Honor #:tests? flag.
gnu: fenics: Honor #:tests? flag.
gnu: fenics: Fix sanity check.
gnu: python-vedo: Honor #:tests? flag.
gnu: python-vedo: Remove input labels.
gnu: python-vedo: Disable sanity check.
gnu: python-vedo: Update to 2022.2.0.

gnu/packages/python-science.scm | 55 ++++++++++++++++++++-------------
gnu/packages/simulation.scm | 49 +++++++++++++++--------------
2 files changed, 59 insertions(+), 45 deletions(-)

--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:25
[PATCH v3 3/7] gnu: fenics: Fix sanity check.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-4-paul@apatience.com
* gnu/packages/simulation.scm (fenics)[arguments]: Relax pybind11
requirement to appease the sanity check.
---
gnu/packages/simulation.scm | 4 ++++
1 file changed, 4 insertions(+)

Toggle diff (15 lines)
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index 230ae62826..b15743f747 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -607,6 +607,10 @@ (define-public fenics
(arguments
`(#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'relax-requirements
+ (lambda _
+ (substitute* "python/setup.py"
+ (("pybind11==") "pybind11>="))))
(add-after 'patch-source-shebangs 'set-paths
(lambda _
;; Define paths to store locations.
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:25
[PATCH v3 1/7] gnu: fenics-dolfin: Honor #:tests? flag.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-2-paul@apatience.com
* gnu/packages/simulation.scm (fenics-dolfin)[source]: Remove trailing
boolean.
[arguments]: Adjust custom 'check' phase to honor the #:tests? flag. While
here, remove trailing booleans.
---
gnu/packages/simulation.scm | 22 ++++++++++------------
1 file changed, 10 insertions(+), 12 deletions(-)

Toggle diff (48 lines)
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm
index 3f2d8e136d..757738e627 100644
--- a/gnu/packages/simulation.scm
+++ b/gnu/packages/simulation.scm
@@ -448,8 +448,7 @@ (define-public fenics-dolfin
;; Specify directory to find the header file.
(("(^set\\(CATCH_INCLUDE_DIR ).*(/catch\\))" _ front back)
(string-append front
- "$ENV{CATCH_DIR}/include" back "\n")))
- #t))))
+ "$ENV{CATCH_DIR}/include" back "\n")))))))
(build-system cmake-build-system)
(inputs
`(("blas" ,openblas)
@@ -494,8 +493,7 @@ (define-public fenics-dolfin
(setenv "SLEPC_DIR" (assoc-ref %build-inputs "slepc"))
(setenv "SCOTCH_DIR" (assoc-ref %build-inputs "scotch"))
(setenv "SUNDIALS_DIR" (assoc-ref %build-inputs "sundials"))
- (setenv "UMFPACK_DIR" (assoc-ref %build-inputs "suitesparse"))
- #t))
+ (setenv "UMFPACK_DIR" (assoc-ref %build-inputs "suitesparse"))))
(add-before 'check 'pre-check
(lambda _
;; The Dolfin repository uses git-lfs, whereby web links are
@@ -546,15 +544,15 @@ (define-public fenics-dolfin
"demo_mesh-quality_serial "
"demo_mesh-quality_mpi "
"demo_multimesh-stokes_serial "
- ")\n") port)))
- #t))
+ ")\n") port)))))
(replace 'check
- (lambda _
- (and (invoke "make" "unittests")
- (invoke "make" "demos")
- (invoke "ctest" "-R" "unittests")
- (invoke "ctest" "-R" "demo" "-R" "serial")
- (invoke "ctest" "-R" "demo" "-R" "mpi")))))))
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "make" "unittests")
+ (invoke "make" "demos")
+ (invoke "ctest" "-R" "unittests")
+ (invoke "ctest" "-R" "demo" "-R" "serial")
+ (invoke "ctest" "-R" "demo" "-R" "mpi")))))))
(home-page "https://bitbucket.org/fenics-project/dolfin/")
(synopsis "Problem solving environment for differential equations")
(description
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:25
[PATCH v3 4/7] gnu: python-vedo: Honor #:tests? flag.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-5-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo)[arguments]: Adjust
custom 'check' phase to honor the #:tests? flag. Also remove its
trailing boolean.
---
gnu/packages/python-science.scm | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)

Toggle diff (29 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 07d713e013..4538904b68 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -876,15 +876,15 @@ (define-public python-vedo
(add-after 'build 'mpi-setup
,%openmpi-setup)
(replace 'check
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (setenv "HOME" (getcwd))
- (add-installed-pythonpath inputs outputs)
- (with-directory-excursion "tests"
- (for-each (lambda (dir)
- (with-directory-excursion dir
- (invoke "./run_all.sh")))
- '("common" "dolfin")))
- #t)))))
+ (lambda* (#:key tests? inputs outputs #:allow-other-keys)
+ (when tests?
+ (setenv "HOME" (getcwd))
+ (add-installed-pythonpath inputs outputs)
+ (with-directory-excursion "tests"
+ (for-each (lambda (dir)
+ (with-directory-excursion dir
+ (invoke "./run_all.sh")))
+ '("common" "dolfin")))))))))
(inputs ; for the check phase
`(("dolfin" ,fenics)
("pkgconfig" ,python-pkgconfig)
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:25
[PATCH v3 5/7] gnu: python-vedo: Remove input labels.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-6-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo)[inputs]: Remove labels
and sort the inputs.
[propagated-inputs]: Remove labels.
---
gnu/packages/python-science.scm | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)

Toggle diff (24 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 4538904b68..3afaa0efc2 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -886,14 +886,14 @@ (define-public python-vedo
(invoke "./run_all.sh")))
'("common" "dolfin")))))))))
(inputs ; for the check phase
- `(("dolfin" ,fenics)
- ("pkgconfig" ,python-pkgconfig)
- ("matplotlib" ,python-matplotlib)))
+ (list fenics
+ python-matplotlib
+ python-pkgconfig))
(native-inputs ; for python-pkgconfig
(list pkg-config))
(propagated-inputs
- `(("numpy" ,python-numpy)
- ("vtk" ,vtk)))
+ (list python-numpy
+ vtk))
(home-page "https://github.com/marcomusy/vedo")
(synopsis
"Analysis and visualization of 3D objects and point clouds")
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:26
[PATCH v3 6/7] gnu: python-vedo: Disable sanity check.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-7-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo)[arguments]: Disable
sanity check.
---
gnu/packages/python-science.scm | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)

Toggle diff (17 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 3afaa0efc2..676ca6474e 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -884,7 +884,11 @@ (define-public python-vedo
(for-each (lambda (dir)
(with-directory-excursion dir
(invoke "./run_all.sh")))
- '("common" "dolfin")))))))))
+ '("common" "dolfin"))))))
+ ;; Disable the sanity check, which fails with the following error:
+ ;;
+ ;; ...checking requirements: ERROR: vedo==2021.0.3 DistributionNotFound(Requirement.parse('vtk'), {'vedo'})
+ (delete 'sanity-check))))
(inputs ; for the check phase
(list fenics
python-matplotlib
--
2.35.1
P
P
Paul A. Patience wrote on 22 Apr 2022 22:26
[PATCH v3 7/7] gnu: python-vedo: Update to 2022.2.0.
(address . 54869@debbugs.gnu.org)(name . Paul A. Patience)(address . paul@apatience.com)
20220422202538.106338-8-paul@apatience.com
* gnu/packages/python-science.scm (python-vedo): Update to 2022.2.0.
[arguments]: Add 'fix-tests' phase.
[inputs]: Move fenics and python-matplotlib to propagated-inputs.
Move python-pkgconfig from here...
[native-inputs]: ...to here.
[propagated-inputs]: Add python-deprecated (and fenics and
python-matplotlib).
[description]: Make description more accurate.
---
gnu/packages/python-science.scm | 31 +++++++++++++++++++------------
1 file changed, 19 insertions(+), 12 deletions(-)

Toggle diff (78 lines)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 676ca6474e..ab307e31af 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -17,6 +17,7 @@
;;; Copyright © 2021 Felix Gruber <felgru@posteo.net>
;;; Copyright © 2022 Malte Frank Gerdes <malte.f.gerdes@gmail.com>
;;; Copyright © 2022 Guillaume Le Vaillant <glv@posteo.net>
+;;; Copyright © 2022 Paul A. Patience <paul@apatience.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -858,21 +859,28 @@ (define-public python-upsetplot
(define-public python-vedo
(package
(name "python-vedo")
- (version "2021.0.3")
+ (version "2022.2.0")
(source
(origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/marcomusy/vedo")
- (commit version)))
+ (commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
- "18i3ajh5jzhpc86di15lwh4jv97jhm627ii877sa4yhv6abzjfpn"))))
+ "1hhv4xc4bphhd1zrnf7r6fpf65xvkdqmb1lh51qg1xpv91h2az0h"))))
(build-system python-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'fix-tests
+ ;; These tests require online data.
+ (lambda _
+ (substitute* "tests/common/test_actors.py"
+ (("^st = .*") "")
+ (("^assert isinstance\\(st\\.GetTexture\\(\\), .*") ""))
+ (delete-file "tests/common/test_pyplot.py")))
(add-after 'build 'mpi-setup
,%openmpi-setup)
(replace 'check
@@ -887,16 +895,16 @@ (define-public python-vedo
'("common" "dolfin"))))))
;; Disable the sanity check, which fails with the following error:
;;
- ;; ...checking requirements: ERROR: vedo==2021.0.3 DistributionNotFound(Requirement.parse('vtk'), {'vedo'})
+ ;; ...checking requirements: ERROR: vedo==2022.2.0 DistributionNotFound(Requirement.parse('vtk<9.1.0'), {'vedo'})
(delete 'sanity-check))))
- (inputs ; for the check phase
- (list fenics
- python-matplotlib
+ (native-inputs
+ (list pkg-config
python-pkgconfig))
- (native-inputs ; for python-pkgconfig
- (list pkg-config))
(propagated-inputs
- (list python-numpy
+ (list fenics
+ python-deprecated
+ python-matplotlib
+ python-numpy
vtk))
(home-page "https://github.com/marcomusy/vedo")
(synopsis
@@ -907,8 +915,7 @@ (define-public python-vedo
range of functionalities for working with three-dimensional meshes and
point clouds. It can also be used to generate high quality
two-dimensional renderings such as scatter plots and histograms.
-@code{vedo} is based on @code{vtk} and @code{numpy}, with no other
-dependencies.")
+@code{vedo} is based on @code{vtk} and @code{numpy}.")
;; vedo is released under the Expat license. Included fonts are
;; covered by the OFL license and textures by the CC0 license.
;; The earth images are in the public domain.
--
2.35.1
L
L
Ludovic Courtès wrote on 6 May 2022 15:11
Re: bug#54874: [PATCH 4/5] gnu: python-vedo: Remove input labels.
(name . Paul A. Patience)(address . paul@apatience.com)
878rre4xh6.fsf_-_@gnu.org
Hi Paul,

"Paul A. Patience" <paul@apatience.com> skribis:

Toggle quote (8 lines)
> gnu: fenics-dolfin: Honor #:tests? flag.
> gnu: fenics: Honor #:tests? flag.
> gnu: fenics: Fix sanity check.
> gnu: python-vedo: Honor #:tests? flag.
> gnu: python-vedo: Remove input labels.
> gnu: python-vedo: Disable sanity check.
> gnu: python-vedo: Update to 2022.2.0.

Finally applied. Thank you, and thanks Maxime for reviewing!

Ludo’.
Closed
M
M
Maxime Devos wrote on 6 May 2022 15:36
Re: [bug#54874] [PATCH 4/5] gnu: python-vedo: Remove input labels.
848c6b4baaf973053fcbebdb0bfd4a551141266b.camel@telenet.be
Ludovic Courtès schreef op vr 06-05-2022 om 15:11 [+0200]:
Toggle quote (2 lines)
> Finally applied.  Thank you, and thanks Maxime for reviewing!

TBC I only looked rather superficially at things, I haven't build any
of the packages myself or looked into the source code of the packages.

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYnUkWRccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7nqeAP9eDLVOKdzpZ7MV99qnekvrr27l
BNEjxIqriAnKO7L4AwEAshWHFTehxvdu/L+3K8KfadoqPl+RaXD+smPHubRVuwk=
=wxXO
-----END PGP SIGNATURE-----


Closed
?