[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
05/07: Handle derivations with no sources
From: |
Christopher Baines |
Subject: |
05/07: Handle derivations with no sources |
Date: |
Thu, 9 Nov 2023 11:45:02 -0500 (EST) |
cbaines pushed a commit to branch master
in repository data-service.
commit 4f1ae74d2fb7feeaa43fecc773c417a16005d56b
Author: Christopher Baines <mail@cbaines.net>
AuthorDate: Sun Nov 5 18:49:23 2023 +0000
Handle derivations with no sources
---
guix-data-service/model/derivation.scm | 23 ++++++++++++-----------
1 file changed, 12 insertions(+), 11 deletions(-)
diff --git a/guix-data-service/model/derivation.scm
b/guix-data-service/model/derivation.scm
index 4efda3a..d95e285 100644
--- a/guix-data-service/model/derivation.scm
+++ b/guix-data-service/model/derivation.scm
@@ -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)
- branch master updated (2135bc5 -> 37a07c2), Christopher Baines, 2023/11/09
- 05/07: Handle derivations with no sources,
Christopher Baines <=
- 02/07: Restore #:error-port when calling open-inferior, Christopher Baines, 2023/11/09
- 01/07: Remove #:use-module (ice-9 custom-ports), Christopher Baines, 2023/11/09
- 07/07: Try to avoid the metrics timing out, Christopher Baines, 2023/11/09
- 06/07: Add missing empty job log entry, Christopher Baines, 2023/11/09
- 04/07: Handle eof when reading logs, Christopher Baines, 2023/11/09
- 03/07: Remove peek, Christopher Baines, 2023/11/09