import: elpa: Do not abort when failing to download the archive.
* guix/import/elpa.scm (elpa-fetch-archive): Use 'http-fetch/cached' directly instead of 'call-with-downloaded-file'. This ensures we don't just abort when networking access is lacking, which is required to allow 'guix refresh -c refresh' to proceed.
This commit is contained in:
parent
90297811a9
commit
0a2ce1ea0a
|
@ -80,8 +80,11 @@ NAMES (strings)."
|
||||||
(cut string-append <> "/archive-contents"))))
|
(cut string-append <> "/archive-contents"))))
|
||||||
(if url
|
(if url
|
||||||
;; Use a relatively small TTL for the archive itself.
|
;; Use a relatively small TTL for the archive itself.
|
||||||
(parameterize ((%http-cache-ttl (* 6 3600)))
|
(let* ((port (http-fetch/cached (string->uri url)
|
||||||
(call-with-downloaded-file url read))
|
#:ttl (* 6 3600)))
|
||||||
|
(data (read port)))
|
||||||
|
(close-port port)
|
||||||
|
data)
|
||||||
(leave (G_ "~A: currently not supported~%") repo))))
|
(leave (G_ "~A: currently not supported~%") repo))))
|
||||||
|
|
||||||
(define* (call-with-downloaded-file url proc #:optional (error-thunk #f))
|
(define* (call-with-downloaded-file url proc #:optional (error-thunk #f))
|
||||||
|
|
Loading…
Reference in New Issue