Index: configfmod.scm ================================================================== --- configfmod.scm +++ configfmod.scm @@ -1058,25 +1058,27 @@ ((runconfigs-get rget) `(noeval-needed ,(runconfigs-get ht quotedcmd))) ;; (conc "(lambda (ht)(runconfigs-get ht \"" cmd "\"))")) (else `(#f ,(conc "cmd: " cmd " not recognised"))))))) (match fullcmd (('eval-needed newres) -;;(handle-exceptions -;; exn -;; (begin -;; (debug:print 0 *default-log-port* "WARNING: failed to process config input \"" l "\", eval-needed, newres="newres", exn="(condition->list exn)) -;; (debug:print 0 *default-log-port* " message: " ((condition-property-accessor 'exn 'message) exn)) -;; ;; (print "exn=" (condition->list exn)) -;; (set! result (conc "#{( " cmdtype ") " cmd "}, full expansion: " newres))) (if (or allow-system (not (member cmdtype '("system" "shell" "sh")))) - (with-input-from-string newres - (lambda () - (set! result (if env-to-use - ((eval (read) env-to-use) ht) - ((eval (read)) ht) - )))) + (begin + (debug:print 0 *default-log-port* "eval: "newres) + (with-input-from-string newres + (lambda () + (set! result + (handle-exceptions + exn + (begin + (debug:print 0 *default-log-port* "WARNING: failed to process config input \"" l "\", eval-needed, newres="newres", exn="(condition->list exn)) + (debug:print 0 *default-log-port* " message: " ((condition-property-accessor 'exn 'message) exn)) + (set! result (conc "#{( " cmdtype ") " cmd "}, full expansion: " newres))) + (if env-to-use + ((eval (read) env-to-use) ht) + ((eval (read)) ht) + )))))) (set! result (conc "#{(" cmdtype ") " cmd "}")))); ) (('noeval-needed newres)(set! result newres)) (else ;; (#f errres) (debug:print 0 *default-log-port* "WARNING: failed to process config input \""l"\", fullcmd="fullcmd"."))) ;; we process as a result