aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2020-02-24 19:00:58 +0000
committerChristopher Baines <mail@cbaines.net>2020-02-24 19:00:58 +0000
commit75d9a0f30ab29e135ef8a7cdc9dc9bf61d172519 (patch)
tree2092eeee62dbd26def0bd8bd53565f560aa598f8
parent1f51ad1baaafd9a2d621a7682900a373356835db (diff)
downloaddata-service-75d9a0f30ab29e135ef8a7cdc9dc9bf61d172519.tar
data-service-75d9a0f30ab29e135ef8a7cdc9dc9bf61d172519.tar.gz
WIP
-rw-r--r--Makefile.am1
-rw-r--r--guix-data-service/jobs/load-new-guix-revision.scm39
2 files changed, 20 insertions, 20 deletions
diff --git a/Makefile.am b/Makefile.am
index 85c4c32..d1e8ab6 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -70,6 +70,7 @@ SOURCES = \
guix-data-service/comparison.scm \
guix-data-service/config.scm \
guix-data-service/database.scm \
+ guix-data-service/utils.scm \
guix-data-service/data-deletion.scm \
guix-data-service/jobs.scm \
guix-data-service/jobs/load-new-guix-revision.scm \
diff --git a/guix-data-service/jobs/load-new-guix-revision.scm b/guix-data-service/jobs/load-new-guix-revision.scm
index 7001333..2f1dfa4 100644
--- a/guix-data-service/jobs/load-new-guix-revision.scm
+++ b/guix-data-service/jobs/load-new-guix-revision.scm
@@ -35,6 +35,7 @@
#:use-module (guix build utils)
#:use-module (guix-data-service config)
#:use-module (guix-data-service database)
+ #:use-module (guix-data-service utils)
#:use-module (guix-data-service model build)
#:use-module (guix-data-service model channel-instance)
#:use-module (guix-data-service model channel-news)
@@ -1616,26 +1617,24 @@ SKIP LOCKED")
(if (or
(guix-revision-exists? conn git-repository-id commit)
(eq?
- (log-time
- (string-append "loading revision " commit)
- (lambda ()
- (setup-logging
- id
- (lambda ()
- (catch #t
- (lambda ()
- (with-store-connection
- (lambda (store)
- (load-new-guix-revision conn
- store
- git-repository-id
- commit))))
- (lambda (key . args)
- (simple-format
- (current-error-port)
- "error: load-new-guix-revision: ~A ~A\n"
- key args)
- #f))))))
+ (with-time-logging (string-append "loading revision " commit)
+ (setup-logging
+ id
+ (lambda ()
+ (catch #t
+ (lambda ()
+ (with-store-connection
+ (lambda (store)
+ (load-new-guix-revision conn
+ store
+ git-repository-id
+ commit))))
+ (lambda (key . args)
+ (simple-format
+ (current-error-port)
+ "error: load-new-guix-revision: ~A ~A\n"
+ key args)
+ #f)))))
#t))
(begin
(record-job-succeeded conn id)