guix_mirror_bot pushed a commit to branch astro-updates
in repository guix.

commit 091abd66ab69c7640e7201d7e58959e2a50a7b2d
Author: Sharlatan Hellseher <sharlata...@gmail.com>
AuthorDate: Thu Sep 18 14:26:32 2025 +0100

    gnu: python-jplephem: Update to 2.23.
    
    * gnu/packages/astronomy.scm (python-jplephem): Update to 2.23.
    [source]: Switch to git-fetch providing test data.
    [phases]{check}: Rework test steps.
    [native-inputs]: Remove python-setuptools and python-wheel; add
    python-setuptools-next.
    
    (python-jplephem-2.22): New variable.
    
    (python-astropy-6)[propagated-inputs]: Remove python-jplephem; add
    python-jplephem-2.22
    
    Change-Id: I9a53357a3c06c219a5620b5d23ce640b2a5d70db
---
 gnu/packages/astronomy.scm | 46 ++++++++++++++++++++++++++++++++++++++--------
 1 file changed, 38 insertions(+), 8 deletions(-)

diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm
index f8a4448668..80107af4dd 100644
--- a/gnu/packages/astronomy.scm
+++ b/gnu/packages/astronomy.scm
@@ -2906,7 +2906,10 @@ astronomy and astrophysics.")
            (with-directory-excursion "astropy/extern"
              (for-each delete-file-recursively '("ply" "configobj")))
            (with-directory-excursion "cextern"
-             (for-each delete-file-recursively '("expat" "wcslib")))))))))
+             (for-each delete-file-recursively '("expat" "wcslib")))))))
+    (propagated-inputs
+     (modify-inputs (package-propagated-inputs python-astropy)
+       (replace "python-jplephem" python-jplephem-2.22)))))
 
 (define-public python-astropy-healpix
   (package
@@ -4945,13 +4948,16 @@ satellite.")
 (define-public python-jplephem
   (package
     (name "python-jplephem")
-    (version "2.22")
+    (version "2.23")
     (source
      (origin
-       (method url-fetch)
-       (uri (pypi-uri "jplephem" version))
+       (method git-fetch)       ;no tests data in the PyPI tarball
+       (uri (git-reference
+              (url "https://github.com/brandon-rhodes/python-jplephem";)
+              (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32 "0b2rgb7pvwnl72pqjryf9c812mmdxr69fwiym7mnz05l2xrcr6hd"))))
+        (base32 "0mmd30cymb9f259c657d7jd65plirdsngnk14fbyjxd9vbryn2qa"))))
     (build-system pyproject-build-system)
     (arguments
      (list
@@ -4960,10 +4966,10 @@ satellite.")
           (replace 'check
             (lambda* (#:key tests? #:allow-other-keys)
               (when tests?
-                (invoke "python" "-m" "unittest" "discover" "-s" "test")))))))
+                (with-directory-excursion "ci"
+                  (invoke "python" "-m" "unittest" "test"))))))))
     (native-inputs
-     (list python-setuptools
-           python-wheel))
+     (list python-setuptools-next))
     (propagated-inputs
      (list python-numpy))
     (home-page "https://github.com/brandon-rhodes/python-jplephem";)
@@ -4976,6 +4982,30 @@ Astronomical Almanac to within 0.0005 arcseconds (half a 
@emph{mas} or
 milliarcsecond).")
     (license license:expat)))
 
+;; The last compatible version for python-astropy-6.
+(define-public python-jplephem-2.22
+  (hidden-package
+   (package
+     (inherit python-jplephem)
+     (version "2.22")
+     (source
+      (origin
+        (method url-fetch)
+        (uri (pypi-uri "jplephem" version))
+        (sha256
+         (base32 "0b2rgb7pvwnl72pqjryf9c812mmdxr69fwiym7mnz05l2xrcr6hd"))))
+    (arguments
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (replace 'check
+            (lambda* (#:key tests? #:allow-other-keys)
+              (when tests?
+                (invoke "python" "-m" "unittest" "discover" "-s" "test")))))))
+    (native-inputs
+     (list python-setuptools
+           python-wheel)))))
+
 (define-public python-jwst
   (package
     (name "python-jwst")

Reply via email to