Guard against build being missing from the output response

This commit is contained in:
Christopher Baines 2020-02-16 09:06:12 +00:00
parent cc370fae56
commit 6f97cec962

View file

@ -234,6 +234,8 @@ initial connection on which HTTP requests are sent."
(if data (if data
(catch #t (catch #t
(lambda () (lambda ()
(when (assoc-ref data "build")
;; The build can be #f
(let* ((derivation (let* ((derivation
(assoc-ref data "derivation")) (assoc-ref data "derivation"))
(build-id (build-id
@ -253,7 +255,7 @@ initial connection on which HTTP requests are sent."
(if (verbose-output?) (if (verbose-output?)
(simple-format #t "found build for: ~A (~A)\n" (simple-format #t "found build for: ~A (~A)\n"
output derivation) output derivation)
(display "-")))) (display "-")))))
(lambda (key . args) (lambda (key . args)
(simple-format (simple-format
(current-error-port) (current-error-port)