summaryrefslogtreecommitdiff
path: root/gnu/packages/ruby.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2022-09-23 08:00:13 +0200
committerLudovic Courtès <ludo@gnu.org>2022-09-28 22:28:27 +0200
commit8bd4126917f59f4af9a4323c3d5699201862dca2 (patch)
treed5b9f225a0722239269f75c2b471394aa19f4b94 /gnu/packages/ruby.scm
parentf75592533e1921f4b3614a0de345f5c037b90cd6 (diff)
substitute: Retry downloading when a nar is unavailable.
Fixes <https://issues.guix.gnu.org/57978> Reported by Attila Lendvai <attila@lendvai.name>. Previously, if a narinfo was available but its corresponding nar was missing (for instance because the narinfo was cached and the server became unreachable in the meantime), 'guix substitute --substitute' would try to download the nar from its preferred location and abort when that fails. This change forces one retry with each of the URLs. * guix/scripts/substitute.scm (download-nar): Do not catch 'http-get-error?' exceptions. (system-error?, network-error?, process-substitution/fallback): New procedures. (process-substitution): Call 'process-substitution/fallback' upon 'network-error?'. * tests/substitute.scm ("substitute, first URL has narinfo but lacks nar, second URL unauthorized") ("substitute, first URL has narinfo but nar is 404, both URLs authorized") ("substitute, first URL has narinfo but nar is 404, one URL authorized") ("substitute, narinfo is available but nar is missing"): New tests.
Diffstat (limited to 'gnu/packages/ruby.scm')
0 files changed, 0 insertions, 0 deletions