guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[no subject]


From: Ludovic Courtès
Date: Wed, 23 Oct 2019 10:31:36 -0400 (EDT)

branch: master
commit 15fc2d76919171a5f3ef1f32654e9509f3b246db
Author: Ludovic Courtès <address@hidden>
Date:   Wed Oct 23 14:33:36 2019 +0200

    base: Log the evaluation ID upon evaluation failure.
    
    * src/cuirass/base.scm (&evaluation-error)[id]: New field.
    (evaluate): Specify the 'id' field.
    (process-specs): Show the log file name upon evaluation failure.
---
 src/cuirass/base.scm | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/src/cuirass/base.scm b/src/cuirass/base.scm
index 00b1daa..3dbc5f4 100644
--- a/src/cuirass/base.scm
+++ b/src/cuirass/base.scm
@@ -258,7 +258,8 @@ TARGET beforehand if it exists.  Return TARGET."
 
 (define-condition-type &evaluation-error &error
   evaluation-error?
-  (name evaluation-error-spec-name))
+  (name evaluation-error-spec-name)
+  (id   evaluation-error-id))
 
 (define (non-blocking-port port)
   "Make PORT non-blocking and return it."
@@ -351,7 +352,8 @@ Return a list of jobs that are associated to EVAL-ID."
                     (close-port (cdr log-pipe))
                     (raise (condition
                             (&evaluation-error
-                             (name (assq-ref spec #:name))))))
+                             (name (assq-ref spec #:name))
+                             (id eval-id)))))
                    (data data))))
     (close-port (cdr log-pipe))
     (close-pipe port)
@@ -764,8 +766,10 @@ started)."
           (spawn-fiber
            (lambda ()
              (guard (c ((evaluation-error? c)
-                        (log-message "failed to evaluate spec '~a'"
-                                     (evaluation-error-spec-name c))
+                        (log-message "failed to evaluate spec '~a'; see ~a"
+                                     (evaluation-error-spec-name c)
+                                     (evaluation-log-file
+                                      (evaluation-error-id c)))
                         #f))
                (log-message "evaluating spec '~a'" name)
                (with-store store



reply via email to

[Prev in Thread] Current Thread [Next in Thread]