GNU bug report logs - #53447
[PATCH] doc: Unset environment variables considered harmful

Previous Next

Package: guix-patches;

Reported by: Liliana Marie Prikler <liliana.prikler <at> gmail.com>

Date: Sat, 22 Jan 2022 14:17:01 UTC

Severity: normal

Tags: patch

Full log


View this message in rfc822 format

From: Ludovic Courtès <ludo <at> gnu.org>
To: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Cc: 53447 <at> debbugs.gnu.org, Liliana Marie Prikler <liliana.prikler <at> gmail.com>
Subject: [bug#53447] Introducing ‘GUIX_’-prefixed environment variables
Date: Tue, 25 Jan 2022 14:29:41 +0100
Hi,

Maxim Cournoyer <maxim.cournoyer <at> gmail.com> skribis:

> I like to see this as a bug, so I've opened one as 53514; Guix should
> strive to not mess with the host environment, and setting global
> variables used by both Guix and a potentially foreign host goes against
> this.  The proper fix would be to patch all applications in Guix to use
> Guix-specific variables, such as GUIX_XDG_DATA_DIRS instead of
> XDG_DATA_DIRS.

This approach has its appeal (like in the ‘GUIX_PYTHONPATH’ case), but
there’s a tension with our other unwritten (?) guideline that we should
modify packages as little as possible.

Such wide-ranging changes would have the unfortunate effect that they’d
make Guix packages “special”: documentation, bug reports, suggestions
you’d find online would apply to the “real” package, but maybe not to
the Guix one.  That is a situation we’d rather avoid IMO.


‘XDG_DATA_DIRS’ is a real problem though.  In large part that’s because
its purpose is too broad—what “data dirs” are we talking about?  It
would be ideal if we could progressively replace ‘XDG_DATA_DIRS’ search
path specifications with more specific environment variables, when they
exist, or perhaps by using ‘wrap-program’ instead of having search path
specs.

Right now there are 9 packages that have ‘XDG_DATA_DIRS’ as their search
path, including 4 Common Lisp packages.  Of the remaining ones, I guess
those we should first focus on are glib and qtbase.

Thoughts?

Ludo’.




This bug report was last modified 3 years and 140 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.