[openstack-dev] why do we use pip -U in tox.ini?

Clint Byrum clint at fewbar.com
Sun Jan 5 16:10:11 UTC 2014

Excerpts from Sean Dague's message of 2014-01-05 07:47:22 -0800:
> While waiting some inordinate amount of time to compile lxml for a 
> tempest pep8 test, I started to wonder why is it that we are using -U on 
> all our pip install commands in tox (it's a pretty common pattern across 
> projects).
> It seems like requirements should be sufficient. Forcing -U to the 
> latest all the time seems like it would actually mask a ton of problems, 
> and makes sitepackages = True to be largely useless.
> I'm sure it went in for a reason, so I'd love to understand the reason, 
> to make sure that my instinct in disabling it in Tempest doesn't have a 
> ton of side effects.

I tend to just use tox without -r, which means re-using the existing
virtualenv. It occasionally means a failed run because I've missed a
requirements change, but that just means when I get a weird failure I
run with -r, which then builds me a new virtualenv.

Would be cool if we could just have tox auto-detect when it even needs to
rebuild the virtualenv, making this dance unnecessary, as I think that
would be preferable to what I suspect you're doing, which is running
with -r all the time?

More information about the OpenStack-dev mailing list