diff options
| author | Hugo Buddelmeijer <hugo@buddelmeijer.nl> | 2026-08-04 17:05:28 +0200 |
|---|---|---|
| committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2026-08-06 14:12:25 +0100 |
| commit | 7e843e13ac3ff17507aa49f1cacea1764731ff68 (patch) | |
| tree | 85ef555bdb4c92a5bd71a82e87c47d7e7c4adc6c /gnu | |
| parent | c8b21f613a39b53bfa1d7fb0140933e2b79e9d65 (diff) | |
gnu: python-astropy: Disable downloading of iers data by default.
* gnu/packages/astronomy.scm (python-astropy): Add no download patch.
[source]: Add new patch.
* gnu/packages/patches/python-astropy-dont-download-iers-data.patch: Add file.
* gnu/local.mk (dist_patch_DATA): Register patch.
Merges: guix/guix!10344
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Diffstat (limited to 'gnu')
| -rw-r--r-- | gnu/local.mk | 1 | ||||
| -rw-r--r-- | gnu/packages/astronomy.scm | 17 | ||||
| -rw-r--r-- | gnu/packages/patches/python-astropy-dont-download-iers-data.patch | 27 |
3 files changed, 45 insertions, 0 deletions
diff --git a/gnu/local.mk b/gnu/local.mk index 362f5ca500f..3b91a9eb623 100644 --- a/gnu/local.mk +++ b/gnu/local.mk | |||
| @@ -2138,6 +2138,7 @@ dist_patch_DATA = \ | |||
| 2138 | %D%/packages/patches/python-3.12-fix-tests.patch \ | 2138 | %D%/packages/patches/python-3.12-fix-tests.patch \ |
| 2139 | %D%/packages/patches/python-3.13-fix-tests.patch \ | 2139 | %D%/packages/patches/python-3.13-fix-tests.patch \ |
| 2140 | %D%/packages/patches/python-anyio-unuse-exceptiongroup-in-test.patch \ | 2140 | %D%/packages/patches/python-anyio-unuse-exceptiongroup-in-test.patch \ |
| 2141 | %D%/packages/patches/python-astropy-dont-download-iers-data.patch \ | ||
| 2141 | %D%/packages/patches/python-beangulp-click-8.2-compat.patch \ | 2142 | %D%/packages/patches/python-beangulp-click-8.2-compat.patch \ |
| 2142 | %D%/packages/patches/python-bed-reader-use-store-samples.patch \ | 2143 | %D%/packages/patches/python-bed-reader-use-store-samples.patch \ |
| 2143 | %D%/packages/patches/python-chai-drop-python2.patch \ | 2144 | %D%/packages/patches/python-chai-drop-python2.patch \ |
diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 89fa4f33988..4a7387b1910 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm | |||
| @@ -3421,6 +3421,23 @@ constraints (i.e., altitude, airmass, moon separation/illumination, etc.) | |||
| 3421 | (sha256 | 3421 | (sha256 |
| 3422 | (base32 "1nji4flblxsq9mgiahx3r3wyfkdr5nir2iqab76r98hzp7ak3jj5")) | 3422 | (base32 "1nji4flblxsq9mgiahx3r3wyfkdr5nir2iqab76r98hzp7ak3jj5")) |
| 3423 | (modules '((guix build utils))) | 3423 | (modules '((guix build utils))) |
| 3424 | (patches | ||
| 3425 | ;; Do not download updated iers data on the fly. Refresh the | ||
| 3426 | ;; python-astropy-iers-data package instead. | ||
| 3427 | ;; That is, the python-astropy-iers-data package contains tables with | ||
| 3428 | ;; an expiration date, for example with leap second information. | ||
| 3429 | ;; The astropy.time package will try to download updated data | ||
| 3430 | ;; once the current date is within 5 months of the expiration date. | ||
| 3431 | ;; For reproducibility reasons it is more idiomatic to disable the | ||
| 3432 | ;; downloading and instead regularly update python-astropy-iers-data. | ||
| 3433 | ;; In particular some tests python-astropy and some dependent packages | ||
| 3434 | ;; will fail 5 months 'into the future' because they will trigger this | ||
| 3435 | ;; downloading of data. This patch ensures that these packages can | ||
| 3436 | ;; still be build with guix time-machine. | ||
| 3437 | ;; E.g., this command, using a commit before this patch, will fail: | ||
| 3438 | ;; guix time-machine --commit=86813d5779253bb50002d79ab791eeda5a8b4729 | ||
| 3439 | ;; -- build python-astropy | ||
| 3440 | (search-patches "python-astropy-dont-download-iers-data.patch")) | ||
| 3424 | (snippet | 3441 | (snippet |
| 3425 | '(begin | 3442 | '(begin |
| 3426 | ;; Remove Python bundles. | 3443 | ;; Remove Python bundles. |
diff --git a/gnu/packages/patches/python-astropy-dont-download-iers-data.patch b/gnu/packages/patches/python-astropy-dont-download-iers-data.patch new file mode 100644 index 00000000000..6c1d9626a5a --- /dev/null +++ b/gnu/packages/patches/python-astropy-dont-download-iers-data.patch | |||
| @@ -0,0 +1,27 @@ | |||
| 1 | commit e1e8631583ae26b1ac521afcf9b4f1fd640427fe | ||
| 2 | Author: Hugo Buddelmeijer <hugo@buddelmeijer.nl> | ||
| 3 | Date: Tue Aug 4 09:33:22 2026 +0200 | ||
| 4 | |||
| 5 | Set iers auto_download default to False. | ||
| 6 | |||
| 7 | diff --git a/astropy/utils/iers/iers.py b/astropy/utils/iers/iers.py | ||
| 8 | index 0541831366..acaf36826b 100644 | ||
| 9 | --- a/astropy/utils/iers/iers.py | ||
| 10 | +++ b/astropy/utils/iers/iers.py | ||
| 11 | @@ -166,13 +166,14 @@ class Conf(_config.ConfigNamespace): | ||
| 12 | """ | ||
| 13 | |||
| 14 | auto_download = _config.ConfigItem( | ||
| 15 | - True, | ||
| 16 | + False, | ||
| 17 | "Enable auto-downloading of the latest IERS-A data. If set to False " | ||
| 18 | "then the bundled IERS-A file will be used by default (even if a " | ||
| 19 | "newer version of the IERS-A file was previously downloaded and cached). " | ||
| 20 | "This parameter also controls whether internet resources will be " | ||
| 21 | "queried to update the leap second table if the installed version is " | ||
| 22 | - "out of date. Default is True.", | ||
| 23 | + "out of date. Default is False in Guix for reproducibility. Refresh" | ||
| 24 | + "the python-astropy-iers-data package instead.", | ||
| 25 | ) | ||
| 26 | auto_max_age = _config.ConfigItem( | ||
| 27 | 30.0, | ||
