aboutsummaryrefslogtreecommitdiff
path: root/guix/scripts
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2023-12-02 12:04:23 +0100
committerLudovic Courtès <ludo@gnu.org>2023-12-04 22:26:36 +0100
commit06b9c1260c72935806957bf302c40c1db6101a63 (patch)
tree2db1f47c7085c947001719fee6cddfc5eb55ebc4 /guix/scripts
parentd83d4488da5c3bb65867bffa2b8587a7c7b056cc (diff)
downloadguix-06b9c1260c72935806957bf302c40c1db6101a63.tar
guix-06b9c1260c72935806957bf302c40c1db6101a63.tar.gz
substitute: Do not exit when failing to find a nar.
Fixes <https://issues.guix.gnu.org/67575>. * guix/scripts/substitute.scm (process-substitution/fallback): Use ‘report-error’ instead of ‘leave’. Write status line to PORT. * tests/substitute.scm ("substitute, narinfo is available but nar is missing"): Adjust accordingly. Change-Id: Ic7297dbd563c007111ec2167c8d52505a07d4822
Diffstat (limited to 'guix/scripts')
-rwxr-xr-xguix/scripts/substitute.scm5
1 files changed, 3 insertions, 2 deletions
diff --git a/guix/scripts/substitute.scm b/guix/scripts/substitute.scm
index 126f0f9c69..37cd08e289 100755
--- a/guix/scripts/substitute.scm
+++ b/guix/scripts/substitute.scm
@@ -635,8 +635,9 @@ way to download the nar."
(let loop ((cache-urls cache-urls))
(match cache-urls
(()
- (leave (G_ "failed to find alternative substitute for '~a'~%")
- (narinfo-path narinfo)))
+ (report-error (G_ "failed to find alternative substitute for '~a'~%")
+ (narinfo-path narinfo))
+ (display "not-found\n" port))
((cache-url rest ...)
(match (lookup-narinfos cache-url
(list (narinfo-path narinfo))