Handle derivations with no sources
This commit is contained in:
parent
341eb4a283
commit
4f1ae74d2f
|
@ -1652,17 +1652,18 @@ LIMIT $1"
|
|||
(simple-format
|
||||
#t "debug: insert-missing-derivations: inserting sources\n")
|
||||
(for-each (lambda (derivation-id derivation)
|
||||
(let* ((sources (derivation-sources derivation))
|
||||
(sources-ids
|
||||
(insert-derivation-sources conn
|
||||
derivation-id
|
||||
sources)))
|
||||
(map (lambda (id source-file)
|
||||
(insert-derivation-source-file-nar conn
|
||||
id
|
||||
source-file))
|
||||
sources-ids
|
||||
sources)))
|
||||
(let ((sources (derivation-sources derivation)))
|
||||
(unless (null? sources)
|
||||
(let ((sources-ids
|
||||
(insert-derivation-sources conn
|
||||
derivation-id
|
||||
sources)))
|
||||
(map (lambda (id source-file)
|
||||
(insert-derivation-source-file-nar conn
|
||||
id
|
||||
source-file))
|
||||
sources-ids
|
||||
sources)))))
|
||||
derivation-ids
|
||||
derivations)
|
||||
|
||||
|
|
Loading…
Reference in New Issue