[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#33911: SWH fallback is never reached due to an uncaught exception

From: Björn Höfling
Subject: bug#33911: SWH fallback is never reached due to an uncaught exception
Date: Sat, 29 Dec 2018 16:47:45 +0100

git-download has a built-in option to download from Software Heritage
(SWH) as a fall-back, when a repository is unavailable. Unfortunately,
that code is never reached:

./pre-inst-env guix build guile-bash --no-substitutes --no-grafts -S

The following derivation will be built:
environment variable `PATH' set to 
Initialized empty Git repository in 
fatal: repository 
 not found
Failed to do a shallow fetch; retrying a full fetch...
fatal: repository 
 not found
           3 (primitive-load "/gnu/store/4qlm9ih5nhwj38jl46vdy3s37qj?")
In ice-9/eval.scm:
   293:34  2 (_ #<directory (guile-user) 5ce140>)
In ./guix/build/git.scm:
    50:10  1 (git-fetch "https://anonscm.debian.org/cgit/users/kact?"; ?)
In ./guix/build/utils.scm:
    616:6  0 (invoke _ . _)

./guix/build/utils.scm:616:6: In procedure invoke:
Throw to key `srfi-34' with args `(#<condition &invoke-error [program: 
arguments: ("fetch" "origin") exit-status: 128 term-signal: #f stop-signal: #f] 
builder for 
 failed with exit code 1
build of 
View build log at 
guix build: error: build failed: build of 

The code is in git-download.scm, line 133:

            (or (git-fetch (getenv "git url") (getenv "git commit")
                           #:recursive? recursive?
                           #:git-command (string-append #+git "/bin/git"))
                (download-nar #$output)

                ;; As a last resort, attempt to download from Software Heritage.
                ;; XXX: Currently recursive checkouts are not supported.
                (and (not recursive?)
                     (swh-download (getenv "git url") (getenv "git commit")

If I change the order of the or and add the shw-download first, it


Attachment: pgpdPUl6XMole.pgp
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]