guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: installing python 2 and python 3 in the same profile


From: Pjotr Prins
Subject: Re: installing python 2 and python 3 in the same profile
Date: Sun, 11 Mar 2018 13:42:39 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Sun, Mar 11, 2018 at 12:10:09PM +0100, Ricardo Wurmus wrote:
> Obviously, I strongly disagree :)
 
You should ;)

> On my CentOS and Fedora machines at work both versions are installed
> (with the system package manager) and nobody complains.  I can conjure
> up a Python 2 environment by calling “python2” and a Python 3
> environment by calling “python3” or “python”.  Neither variant will load
> up modules for the other variant — unlike the behaviour on Guix.
> 
> Even in Guix we allow these packages to be added to the same environment
> with “guix environment --ad-hoc” – and there are no collisions, because
> upstream made the effort to ensure that these packages don’t provide
> files of the same names.
> 
> It is an unnecessary restriction to *prevent* users from installing
> Python 2 and 3 interpreters into the same profile.  Any errors we see
> with mixing 2 and 3 is due to a bug in Guix which is due to our use of
> PYTHONPATH.

Alright, if you choose to use them as two different tools/languages.

But even in minor versions there are problems. Ruby has those too, I
know for a fact, though Python may be worse since it uses compiled
sources.

> In large environments Python 2 and 3 modules and interpreters can
> peacefully coexist as long as the tools use the appropriate names for
> the interpreters (“python2” or “python” for Python 2, “python3” for
> the interpreter for Python 3).
> 
> In other places in Guix we don’t even prevent users from doing things
> that are generally ill-advised (e.g. the use of LD_LIBRARY_PATH); why
> would we prevent a perfectly valid use-case when it comes to different
> versions of Python?

Sure. Note that Python2 is quickly becoming obsolete. It is escalating
because packages are now dropping support. After 10 years of joy
mixing versions...

Pj.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]