From 15b94238c58c0da42d6e534040e79b0e111178bd Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Sat, 28 Sep 2019 23:56:41 +0100 Subject: Unset the GUILE_LOAD_* environment variables when using inferiors Otherwise modules from outside of the inferior can leak in. --- guix-data-service/jobs/load-new-guix-revision.scm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/guix-data-service/jobs/load-new-guix-revision.scm b/guix-data-service/jobs/load-new-guix-revision.scm index 349a86e..6d99862 100644 --- a/guix-data-service/jobs/load-new-guix-revision.scm +++ b/guix-data-service/jobs/load-new-guix-revision.scm @@ -736,6 +736,15 @@ WHERE job_id = $1" (glibc-locales-for-guix-store-path store store-path) "/lib/locale" ":" guix-locpath))) + ;; Unset the GUILE_LOAD_PATH and GUILE_LOAD_COMPILED_PATH to + ;; avoid the values for these being used in the + ;; inferior. Even though the inferior %load-path and + ;; %load-compiled-path has the inferior modules first, this + ;; can cause issues when there are modules present outside + ;; of the inferior Guix which aren't present in the inferior + ;; Guix (like the new (guix lint) module + (unsetenv "GUILE_LOAD_PATH") + (unsetenv "GUILE_LOAD_COMPILED_PATH") ;; Augment the GUIX_LOCPATH to include glibc-locales from ;; the Guix at store-path, this should mean that the ;; inferior Guix works, even if it's build using a different -- cgit v1.2.3