From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: Anomalies in Python search-path Date: Sun, 15 Jan 2017 23:10:35 +0100 Message-ID: <871sw4ezz8.fsf@gnu.org> References: <8737gw2fqw.fsf@gmail.com> <87tw98mgj9.fsf@gnu.org> <878tqgtehv.fsf@gmail.com> <87shollepw.fsf@gnu.org> <87inpgi4xc.fsf_-_@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:42734) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cSt0e-0006PX-N8 for guix-devel@gnu.org; Sun, 15 Jan 2017 17:10:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cSt0d-0003IK-Om for guix-devel@gnu.org; Sun, 15 Jan 2017 17:10:44 -0500 In-Reply-To: <87inpgi4xc.fsf_-_@gmail.com> (Maxim Cournoyer's message of "Sun, 15 Jan 2017 09:55:27 -0800") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Maxim Cournoyer Cc: guix-devel@gnu.org Maxim Cournoyer skribis: > After more testing, the Python search-path we form is always problematic > for pip since the system site-packages will always appear in front of the > user site location (~/.local/...). You=E2=80=99re talking about the search path formed by =E2=80=98guix enviro= nment=E2=80=99, right? > My last reporting that pip was working correctly in non-environment was > wrong because I had failed to logout/login after installing the python > package; after doing so, the behavior is the same as in an environment: > the user site location (~/.local/...) comes after site-packages rather > than before, as would normally be the case. Apparently this is due to > setting a site-packages location with the environment variable > PYTHONPATH, which has precedence over the user site location. ~/.guix-profile/etc/profile prepends things to the search paths, but it=E2=80=99s up to the user whether to source it before or after other definitions have been provided (in .bash_profile or similar). On GuixSD, for instance, my GUILE_LOAD_PATH has: ~/.local and similar entries then ~/.guix-profile/share/guile/site/2.0 then /run/current-system/profile/share/guile/site/2.0 Ludo=E2=80=99.