[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
08/10: substitute: 'lookup-narinfos' returns exactly a list of narinfos.
From: |
Ludovic Courtès |
Subject: |
08/10: substitute: 'lookup-narinfos' returns exactly a list of narinfos. |
Date: |
Wed, 28 Oct 2015 11:04:47 +0000 |
civodul pushed a commit to branch master
in repository guix.
commit a89dde1ed89a53f33556ab12ec73bafe495a796c
Author: Ludovic Courtès <address@hidden>
Date: Wed Oct 28 11:48:27 2015 +0100
substitute: 'lookup-narinfos' returns exactly a list of narinfos.
* guix/scripts/substitute.scm (lookup-narinfos): Filter out #f values
from CACHED, such that the end result is exactly a list of narinfos,
not interspersed with #f.
* guix/scripts/challenge.scm (discrepancies): Assume REMOTE is a list of
narinfos.
---
guix/scripts/challenge.scm | 6 ++----
guix/scripts/substitute.scm | 4 +++-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/guix/scripts/challenge.scm b/guix/scripts/challenge.scm
index 19a9b06..4a0c865 100644
--- a/guix/scripts/challenge.scm
+++ b/guix/scripts/challenge.scm
@@ -125,10 +125,8 @@ taken since we do not import the archives."
servers))
;; No 'assert-valid-narinfo' on purpose.
(narinfos -> (fold (lambda (narinfo vhash)
- (if narinfo
- (vhash-cons (narinfo-path
narinfo) narinfo
- vhash)
- vhash))
+ (vhash-cons (narinfo-path narinfo)
narinfo
+ vhash))
vlist-null
remote)))
(return (filter-map (lambda (item local)
diff --git a/guix/scripts/substitute.scm b/guix/scripts/substitute.scm
index 0377bb6..34fee58 100755
--- a/guix/scripts/substitute.scm
+++ b/guix/scripts/substitute.scm
@@ -598,7 +598,9 @@ information is available locally."
(let-values (((valid? value)
(cached-narinfo cache path)))
(if valid?
- (values (cons value cached) missing)
+ (if value
+ (values (cons value cached) missing)
+ (values cached missing))
(values cached (cons path missing)))))
'()
'()
- branch master updated (b1b9e5c -> 5c7bdc9), Ludovic Courtès, 2015/10/28
- 03/10: gnu: linux-libre: On MIPS, the linux image name is vmlinuz, not bzImage., Ludovic Courtès, 2015/10/28
- 05/10: gnu: grub: Use modify-phases and other minor cleanups., Ludovic Courtès, 2015/10/28
- 02/10: gnu: linux-libre: Add case for ARCH=mips., Ludovic Courtès, 2015/10/28
- 01/10: gnu: linux-libre: Add 'supported-systems' field: Intel only for now., Ludovic Courtès, 2015/10/28
- 06/10: gnu: grub: Install documentation., Ludovic Courtès, 2015/10/28
- 04/10: doc: Add texinfo to the requirements when building from git., Ludovic Courtès, 2015/10/28
- 08/10: substitute: 'lookup-narinfos' returns exactly a list of narinfos.,
Ludovic Courtès <=
- 10/10: gnu: python-debian: Avoid @itemize in description., Ludovic Courtès, 2015/10/28
- 09/10: substitute: Honor all the specified server URLs., Ludovic Courtès, 2015/10/28
- 07/10: substitute: 'http-multiple-get' follows 'fold' style., Ludovic Courtès, 2015/10/28