[PATCH 0/3] Add python-triangle, python-pandamesh and update gmsh to 4.13.1.

  • Done
  • quality assurance status badge
Details
2 participants
  • Lars Bilke
  • Sharlatan Hellseher
Owner
unassigned
Submitted by
Lars Bilke
Severity
normal

Debbugs page

Lars Bilke wrote 4 weeks ago
(address . guix-patches@gnu.org)(name . Lars Bilke)(address . lars.bilke@ufz.de)
cover.1739439090.git.lars.bilke@ufz.de
Added new package python-pandamesh which requires gmsh 4.13.1 and python-triangle.

Lars Bilke (3):
gnu: gmsh: Update to 4.13.1.
gnu: Add python-triangle.
gnu: Add python-pandamesh.

gnu/packages/geo.scm | 35 +++++++++++++++++++++++++++++++++++
gnu/packages/maths.scm | 4 ++--
gnu/packages/python-xyz.scm | 33 +++++++++++++++++++++++++++++++++
3 files changed, 70 insertions(+), 2 deletions(-)


base-commit: bcce7f8fa8b821b76591b297f61d473c5972e397
--
2.46.1
Lars Bilke wrote 4 weeks ago
[PATCH 1/3] gnu: gmsh: Update to 4.13.1.
(address . 76259@debbugs.gnu.org)(name . Lars Bilke)(address . lars.bilke@ufz.de)
8d238f95ca4c3e86159c7429d90d2e24d4746195.1739439090.git.lars.bilke@ufz.de
* gnu/packages/maths.scm (gmsh): Update to 4.13.1.

Change-Id: Iee56d09055f0803c4f4bc432402dadb3d34bc107
---
gnu/packages/maths.scm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Toggle diff (24 lines)
diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 4a1637b952..8427b7f6db 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -3437,7 +3437,7 @@ (define-public fast-downward
(define-public gmsh
(package
(name "gmsh")
- (version "4.11.1")
+ (version "4.13.1")
(source
(origin
(method git-fetch)
@@ -3448,7 +3448,7 @@ (define-public gmsh
(string-replace-substring version "." "_")))))
(file-name (git-file-name name version))
(sha256
- (base32 "1d6n7qqj9xpfgh7v5jif565waiqjhahkh21pi5s1vr84y61wxyx8"))
+ (base32 "16abxhadyyj7890lv6cdfxskg25w105pcpqvb5iwf6a59py8na8y"))
(modules '((guix build utils)))
(snippet
'(delete-file-recursively "contrib/metis"))))
--
2.46.1
Lars Bilke wrote 4 weeks ago
[PATCH 2/3] gnu: Add python-triangle.
(address . 76259@debbugs.gnu.org)(name . Lars Bilke)(address . lars.bilke@ufz.de)
64d4e2e3b8a474234bd7875dfc2e90e7e53a21b1.1739439090.git.lars.bilke@ufz.de
* gnu/packages/python-xyz.scm (python-triangle): New variable.

Change-Id: I0bc8f96eaf3c2c7d45277ce2ae54ed3b526f8e15
---
gnu/packages/python-xyz.scm | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)

Toggle diff (53 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 5f359d9c54..dde22ebc27 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -161,6 +161,7 @@
;;; Copyright © 2025 Jordan Moore <lockbox@struct.foo>
;;; Copyright © 2025 Dariqq <dariqq@posteo.net>
;;; Copyright © 2025 Nguyễn Gia Phong <mcsinyx@disroot.org>
+;;; Copyright © 2025 Lars Bilke <lars.bilke@ufz.de>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -36144,6 +36145,38 @@ (define-public python-pyhull
Voronoi diagram.")
(license license:expat)))
+(define-public python-triangle
+ (package
+ (name "python-triangle")
+ (version "20250106")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/drufat/triangle")
+ (commit (string-append "v" version))
+ (recursive? #t)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1fj8a64k94mibdz5i6zzmlgs0bvsfsa5qns33ppv8wl306yxq1d3"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list
+ #:phases #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "pytest" "-v")))))))
+ (propagated-inputs (list python-numpy))
+ (native-inputs (list python-setuptools python-wheel python-pytest))
+ (home-page "https://github.com/drufat/triangle")
+ (synopsis "Python bindings to the triangle library")
+ (description
+ "Triangle is a python wrapper around Jonathan Richard
+Shewchuk's two-dimensional quality mesh generator and delaunay
+triangulator library.")
+ (license license:lgpl3)))
+
(define-public python-opcodes
;; There are no tags in this repo, but 'opcodes/__init__.py' specifies a
;; version number, which is what we use here.
--
2.46.1
Lars Bilke wrote 4 weeks ago
[PATCH 3/3] gnu: Add python-pandamesh.
(address . 76259@debbugs.gnu.org)(name . Lars Bilke)(address . lars.bilke@ufz.de)
048a91bda30167d10ed31643fcf0ee6bfc96a1d1.1739439090.git.lars.bilke@ufz.de
* gnu/packages/geo.scm (python-pandamesh): New variable.

Change-Id: I084c772f859cde3be4d4b611cba6b5420067bbe8
---
gnu/packages/geo.scm | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)

Toggle diff (48 lines)
diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm
index d7cef57cde..0070b8a3c1 100644
--- a/gnu/packages/geo.scm
+++ b/gnu/packages/geo.scm
@@ -1091,6 +1091,41 @@ (define-public python-geopandas
require a spatial database such as PostGIS.")
(license license:bsd-3)))
+(define-public python-pandamesh
+ (package
+ (name "python-pandamesh")
+ (version "0.2.3")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/Deltares/pandamesh")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1gnrxw8zxcdkkqzw08lrmnz946bp507r9zn1djhaxxqjs09yzmqp"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list
+ #:phases #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ ;; tests requiring network disabled
+ (invoke "pytest" "-v" "--ignore=tests/test_data.py")))))))
+ (propagated-inputs (list gmsh
+ python-geopandas
+ python-matplotlib
+ python-pooch
+ python-shapely
+ python-triangle
+ python-xarray))
+ (native-inputs (list python-hatchling python-pytest))
+ (home-page "https://deltares.github.io/pandamesh/")
+ (synopsis "From geodataframe to mesh")
+ (description "From geodataframe to mesh.")
+ (license license:expat)))
+
(define-public python-overpass
(package
(name "python-overpass")
--
2.46.1
Sharlatan Hellseher wrote 4 weeks ago
[PATCH 0/3] Add python-triangle, python-pandamesh and update gmsh to 4.13.1.
(address . 76259@debbugs.gnu.org)
87v7tetae9.fsf@gmail.com
Hi Lars,

Thank you for the patches.

I've got some simplification review comments.

Toggle snippet (2 lines)
+ (native-inputs (list python-setuptools python-wheel python-pytest))
Please sort alphabetically.

Toggle snippet (7 lines)
+ (list
+ #:phases #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "pytest" "-v")))))))
This may be removed as pyproject-build-system tries to detect available
test runner e.g. pytest in your case and does all setup within build
system flow.

Toggle snippet (9 lines)
+ (arguments
+ (list
+ #:phases #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ ;; tests requiring network disabled
+ (invoke "pytest" "-v" "--ignore=tests/test_data.py")))))))
Likewise, you may utiize #:test-flags instead of adding custom phase.

Toggle snippet (8 lines)
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/drufat/triangle")
+ (commit (string-append "v" version))
+ (recursive? #t)))
I guess the project contains git submodules, may you double check if may
replace them with our own?

gmsh is save to be refreshed on master:

Toggle snippet (6 lines)
guix refresh --list-dependent gmsh
Building the following 3 packages
would ensure 4 dependent packages are rebuilt: python-pygmsh@7.1.17
openfoam-com@2212 openfoam-org@10.20230119

Waiting for v2!

--
Oleg
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEmEeB3micIcJkGAhndtcnv/Ys0rUFAmetxx4ACgkQdtcnv/Ys
0rXRLA//XxtSAZ+hAelVJm8w4yldqCokr4XCI5mzOGAikVvK+BWch1EOotBytOLo
sxmfhkWPmhl9yPFFT3l1SNkkZ+iL2P1FnSKZwrhFIS8KkabHts2WE8M9Fatz+jXp
90Xtvpq/g5quBBZzE5Bqk9i5DSw9NQBXYpZQDS6axIuVV8rRXpUIRlc3K1WtloaT
6Wd1DintOEbDZYC1NoiLRMAS8Aaabx5sPOPITV28Aqc7gGZEt9TlyAXR5cC0W8oc
NoBTRArF82MIvDNrZ9hVtkQaGhsIJ0Mi1x0ZU7bRVD1EzKv43x7bMrAzNw/QHx13
k4aOpj/42/A0AM7jZmTnk9MGG5auWSGoW9dQDhU6RMzyvGkLvSwmYvMnqE0OanwY
4/CdU9TksgxMWRFmBnhm3Dxq0CebQJxSCgHeOqSjLzkZTHJ58X3Ut42DKiOHTQjR
caCwHp7LLzl8b08ll6mCc7vGrMJm/quxTqNfrAi6911sX7hOeeAJuxlfEoenHrnf
iiXS5s0M49Ijoqzv4GmRzhh27egk7oqe+SGcfvmbjwz7eZg3VfXih8HEoYvydFqY
KmlO/qecQX+FVTJexYOX3WCXcWwO31RMjazZT9HilZx6MLN7zY/ggk5Gy1KZLrCw
ns8r5pwPdO5vVaFeJNJH77L/Vpuyw470fvBFKUpK7bdAkMTE6B8=
=zXlN
-----END PGP SIGNATURE-----

Lars Bilke wrote 4 weeks ago
(address . 76259@debbugs.gnu.org)(name . Sharlatan Hellseher)(address . sharlatanus@gmail.com)
2AC5E454-FEEE-4E11-A58A-039B452A8B5B@ufz.de
Dear Oleg,

thanks a lot for your helpful review!

Unfortunately, I have to retract the patches for python-triangle and python-pandamesh:

Although python-triangle is LGPL licensed, it wraps Jonathan Richard Shewchuks triangle library, which has a proprietary non-commercial license:

Toggle snippet (15 lines)
These programs may be freely redistributed under the condition that the
copyright notices (including the copy of this notice in the code comments
and the copyright notice printed when the `-h' switch is selected) are
not removed, and no compensation is received. Private, research, and
institutional use is free. You may distribute modified versions of this
code UNDER THE CONDITION THAT THIS CODE AND ANY MODIFICATIONS MADE TO IT
IN THE SAME FILE REMAIN UNDER COPYRIGHT OF THE ORIGINAL AUTHOR, BOTH
SOURCE AND OBJECT CODE ARE MADE FREELY AVAILABLE WITHOUT CHARGE, AND
CLEAR NOTICE IS GIVEN OF THE MODIFICATIONS. Distribution of this code as
part of a commercial system is permissible ONLY BY DIRECT ARRANGEMENT
WITH THE AUTHOR. (If you are not directly supplying this code to a
customer, and you are instead telling them how they can obtain it for
free, then you are not required to make any arrangement with me.)

So I think this is not suited for Guix.

Feel free to merge the gmsh update commit and close this issue.

Sincerely,
Lars
Sharlatan Hellseher wrote 4 weeks ago
(address . 76259-done@debbugs.gnu.org)
875xlcu6kz.fsf@gmail.com
Hi Lars,

I've pushed gmsh update after it built succefully on my machine:
Toggle snippet (4 lines)
> ./pre-inst-env guix build gmsh
/gnu/store/p3zgbzgv7gvzj3f2gzfv0b04g7w16dzg-gmsh-4.13.1

Pushed to master as 3a916935311568b742d734cf76be8a45737f9382.
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEmEeB3micIcJkGAhndtcnv/Ys0rUFAmevJCwACgkQdtcnv/Ys
0rUNdBAAj3XDd39odUsi1uWh4U10zP0XU4MMnADNf2aU/dZpucbl6kuqeIlNSanh
yvmT43swm6+UYPDB1+F6XDHBYswVVaiEAhTTZxGaQdq3zALAAsQUEhY48Q1kNRq5
KWUpL4LQFqzsSeVHSEoL7YDlaJPRlba0V7qVpuKS+uRFS+lJUBZQpkZDXEVxSAbo
PfNf7ooi4OxR4SaNMU+T3XcYN0Kf+4PMnz2f8Bja/djHntQo3miRFYnfGmpGGLdU
TM/2QLKJdeSzyJlswGZ1nYLljof0Bp/zWDu1r2Uf2CYDs4AoyHk4v56mVaG4Z2cH
Txj2RoAaTdAiaF/v0fMocmx99yODezuzx+nI2eAEDIlgRlJ5/NmHJVWtj8UeaqfE
+IQKhBi/4Ecvh8rdzBQASNNSe/6jWomQWpQYEt51kM6xm0IWrPgF37Gkyw3a5Ngf
GM/HTsMeXX9dhSh8X8nuODMrTUsrCdYotsozjbsJYl60rwa+SdlnYNaeXQtWRM2b
b4I/tdRc2FrsdzGH/9/EN6YMe1xbdAOj0jQAt1Jv5n24Yp+FfLUWzbfHPyCkfvdh
RCj6H8OeovfwK4XAidTlSFwXbtSmVdYSi2jDx0hmfO4Po0octK+c+KViB8aegGba
hZNciNfDFfujNyrxw9hOXHpJV+rW3f9uz4KlEKnyU0G41G/lqz0=
=DPah
-----END PGP SIGNATURE-----

Closed
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 76259@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 76259
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help