me
/
guix
Archived
1
0
Fork 0

services: herd: "Resolve" transient services only when needed.

This allows us to get rid of the "eval root" actions, which in turn
would lead to confusing "Evaluating user expression" messages.

Fixes <https://issues.guix.gnu.org/55857>.

* gnu/services/herd.scm (resolve-transients): In 'values', avoid
'eval-there' call when UNRESOLVED is empty.
master
Ludovic Courtès 2023-05-27 19:29:33 +02:00
parent e91ceece76
commit d23d8fcee9
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 7 additions and 6 deletions

View File

@ -242,12 +242,13 @@ service is transient."
;; for all of SERVICES.
(let* ((unresolved (filter (compose unspecified? live-service-transient?)
services))
(values (or (eval-there
`(and (defined? 'transient?) ;shepherd >= 0.9.0
(map (compose transient? lookup-running)
',(map (compose first
live-service-provision)
unresolved))))
(values (or (and (pair? unresolved)
(eval-there
`(and (defined? 'transient?) ;shepherd >= 0.9.0
(map (compose transient? lookup-running)
',(map (compose first
live-service-provision)
unresolved)))))
(make-list (length unresolved) #f)))
(resolved (map (lambda (unresolved transient?)
(cons unresolved