[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
06/06: services: dmd: Spawn a REPL upon failure to load a service defini
From: |
Ludovic Courtès |
Subject: |
06/06: services: dmd: Spawn a REPL upon failure to load a service definition. |
Date: |
Wed, 25 Nov 2015 11:00:21 +0000 |
civodul pushed a commit to branch master
in repository guix.
commit b9c7ed71b1c4110c3c8580f1bb8050c31324fa6a
Author: Ludovic Courtès <address@hidden>
Date: Wed Nov 25 11:57:56 2015 +0100
services: dmd: Spawn a REPL upon failure to load a service definition.
Fixes <http://bugs.gnu.org/19779>.
Reported by Mark H Weaver <address@hidden>.
* gnu/services/dmd.scm (dmd-configuration-file)[config]: Wrap
'primitive-load' calls in 'call-with-error-handling'.
---
gnu/services/dmd.scm | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/gnu/services/dmd.scm b/gnu/services/dmd.scm
index 6f70f3d..545087a 100644
--- a/gnu/services/dmd.scm
+++ b/gnu/services/dmd.scm
@@ -223,7 +223,13 @@ stored."
(set! %load-compiled-path
(cons #$compiled %load-compiled-path)))
- (apply register-services (map primitive-load '#$files))
+ (use-modules (system repl error-handling))
+
+ ;; Arrange to spawn a REPL if loading one of FILES fails. This is
+ ;; better than a kernel panic.
+ (call-with-error-handling
+ (lambda ()
+ (apply register-services (map primitive-load '#$files))))
;; guix-daemon 0.6 aborts if 'PATH' is undefined, so work around it.
(setenv "PATH" "/run/current-system/profile/bin")
- branch master updated (3957013 -> b9c7ed7), Ludovic Courtès, 2015/11/25
- 02/06: gexp: Build text derivations locally., Ludovic Courtès, 2015/11/25
- 01/06: gnu: dico: Sort entries in .a files deterministically., Ludovic Courtès, 2015/11/25
- 04/06: services: dmd: Strip the default list of modules., Ludovic Courtès, 2015/11/25
- 06/06: services: dmd: Spawn a REPL upon failure to load a service definition.,
Ludovic Courtès <=
- 05/06: doc: Remove mention of monadic services., Ludovic Courtès, 2015/11/25
- 03/06: services: dmd: Add 'modules' and 'imported-modules' fields., Ludovic Courtès, 2015/11/25