[Mageia-dev] python-virtualenv: package default settings question

Lev Givon lev at columbia.edu
Tue Feb 21 16:58:13 CET 2012


Received from Marja van Waes on Tue, Feb 21, 2012 at 04:42:20AM EST:
> On 20/02/12 20:15, Lev Givon wrote:
> >See https://bugs.mageia.org/show_bug.cgi?id=3358#c3
> >Anyone care to comment?
> >
> >					L.G.
> To make replying easier, here is the question from the above link:
> 
> > By default, virtualenv creates virtual environments using setuptools rather
> > than distribute. This causes virtualenv to complain if  PYTHONDONTWRITEBYTECODE
> > is set (which is the default in Mageia):
> 
> > The PYTHONDONTWRITEBYTECODE environment variable is not compatible with
> > setuptools. Either use --distribute or unset PYTHONDONTWRITEBYTECODE.
> 
> > Do we effectively want to require users to explicitly set the variable in order
> > to use virtualenv with its default settings? (If we do, I can add an
> > installation message to the package to warn users to unset the variable
> > themselves.)
> 
> 
> To me current behaviour as described above sounds strange, even
> irritating, but I'm not a packager and I don't even use the package,
> so I don't know enough.
> 
> @ Lev
> I understand in Mandriva virtualenv the default settings can be used
> without having to unset a variable, and that that doesn't cause
> other problems.  Is that correct?

The Mandriva package uses the same approach as the one in Mageia,
i.e., PYTHONDONTWRITEBYTECODE is unset within
/usr/bin/virtualenv so that it will run successfully without requiring
that the user explicitly unset the variable or run the script with a
specific flag.

Given that the variable is only set when virtualenv is run to create a
virtual environment and does not affect the variable's setting in a
user's session, I'm inclined to leave the package as-is.

> If so, and if no one cares to reply to this mail or in the bug
> report, I think you can just go ahead and change the default
> environment variable from PYTHONDONTWRITEBYTECODE to whatever
> Mandriva's default is. If that causes any new problems, we'll find
> out soon enough when the package is in cauldron ;)
> 
> Regards,
> Marja

						L.G.


More information about the Mageia-dev mailing list