From e0b36b12d7a4ca1a4a105c5f57a3a416585619e2 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Fri, 18 Sep 2020 20:19:03 +0100 Subject: Work around Guile not printing backtraces without failing For some exceptions raised in worker threads, seemingly those that come from guile-sqlite3, Guile can't print the backtrace without erroring itself [1]. Work around Guile not being helpful by just printing out the backtrace, that Guile may fail to print, after the details of the exception. At least then there's something informative in the output. 1: In procedure string->number: Wrong type argument in position 1 (expecting string): #f --- guix-build-coordinator/utils.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guix-build-coordinator/utils.scm b/guix-build-coordinator/utils.scm index 974316f..e9b7ad8 100644 --- a/guix-build-coordinator/utils.scm +++ b/guix-build-coordinator/utils.scm @@ -90,10 +90,10 @@ arguments of the worker thread procedure." (lambda () (with-exception-handler (lambda (exn) - (backtrace) (simple-format (current-error-port) "worker-thread: exception: ~A\n" exn) + (backtrace) (raise-exception exn)) (lambda () (call-with-values -- cgit v1.2.3