Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-15 Thread Radomir Dopieralski
On 12/09/14 17:11, Doug Hellmann wrote: I also use git-hooks with a post-checkout script to remove pyc files any time I change between branches, which is especially helpful if the different branches have code being moved around: git-hooks: https://github.com/icefox/git-hooks The

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-15 Thread Eric Blake
On 09/15/2014 09:29 AM, Radomir Dopieralski wrote: On 12/09/14 17:11, Doug Hellmann wrote: I also use git-hooks with a post-checkout script to remove pyc files any time I change between branches, which is especially helpful if the different branches have code being moved around:

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-15 Thread Brant Knudson
On Mon, Sep 15, 2014 at 1:25 PM, Eric Blake ebl...@redhat.com wrote: On 09/15/2014 09:29 AM, Radomir Dopieralski wrote: On 12/09/14 17:11, Doug Hellmann wrote: I also use git-hooks with a post-checkout script to remove pyc files any time I change between branches, which is especially

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-15 Thread Eric Blake
On 09/15/2014 03:02 PM, Brant Knudson wrote: Good thing that python modules can't have spaces in their names! But for the future, find has a -delete parameter that won't break horribly on strange filenames. find . -name '*.pyc' -delete GNU find has that as an extension, but POSIX does not

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-15 Thread Eric Blake
On 09/15/2014 03:15 PM, Eric Blake wrote: On 09/15/2014 03:02 PM, Brant Knudson wrote: Good thing that python modules can't have spaces in their names! But for the future, find has a -delete parameter that won't break horribly on strange filenames. find . -name '*.pyc' -delete GNU find

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-13 Thread Flavio Percoco
On 09/12/2014 07:14 PM, Doug Hellmann wrote: On Sep 12, 2014, at 12:03 PM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:52 AM, Doug Hellmann wrote: On Sep 12, 2014, at 11:21 AM, Mike Bayer mba...@redhat.com wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I

[openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Sean Dague
I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about why local unit tests are doing completely insane things. The code that it is stack tracing on is no where to be found, and yet it fails. And then you realize that part of oslo

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Brad Topol
Witherspoon (919) 254-0680 From: Sean Dague s...@dague.net To: openstack-dev@lists.openstack.org openstack-dev@lists.openstack.org, Date: 09/12/2014 07:40 AM Subject:[openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini I assume you, gentle OpenStack developers, often

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Doug Hellmann
On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about why local unit tests are doing completely insane things. The code that it is stack tracing on is no where to be

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Mike Bayer
On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about why local unit tests are doing completely insane things. The code that it is stack tracing on is no where to be

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Sean Dague
On 09/12/2014 11:21 AM, Mike Bayer wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about why local unit tests are doing completely insane things. The code that it

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Mike Bayer
On Sep 12, 2014, at 11:24 AM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:21 AM, Mike Bayer wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about why

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Mike Bayer
On Sep 12, 2014, at 11:33 AM, Mike Bayer mba...@redhat.com wrote: On Sep 12, 2014, at 11:24 AM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:21 AM, Mike Bayer wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Doug Hellmann
On Sep 12, 2014, at 11:21 AM, Mike Bayer mba...@redhat.com wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about why local unit tests are doing completely

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Julien Danjou
On Fri, Sep 12 2014, Sean Dague wrote: Which sets PYTHONDONTWRITEBYTECODE=true in the unit tests. This prevents pyc files from being writen in your git tree (win!). It doesn't seem to impact what pip installs... and if anyone knows how to prevent those pyc files from getting created, that

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Sean Dague
On 09/12/2014 11:33 AM, Mike Bayer wrote: On Sep 12, 2014, at 11:24 AM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:21 AM, Mike Bayer wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Sean Dague
On 09/12/2014 11:52 AM, Doug Hellmann wrote: On Sep 12, 2014, at 11:21 AM, Mike Bayer mba...@redhat.com wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume you, gentle OpenStack developers, often find yourself in a hair tearing out moment of frustration about

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Mike Bayer
On Sep 12, 2014, at 12:03 PM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:33 AM, Mike Bayer wrote: On Sep 12, 2014, at 11:24 AM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:21 AM, Mike Bayer wrote: On Sep 12, 2014, at 7:39 AM, Sean Dague s...@dague.net wrote: I assume

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Sean Dague
On 09/12/2014 12:07 PM, Mike Bayer wrote: On Sep 12, 2014, at 12:03 PM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:33 AM, Mike Bayer wrote: On Sep 12, 2014, at 11:24 AM, Sean Dague s...@dague.net wrote: On 09/12/2014 11:21 AM, Mike Bayer wrote: On Sep 12, 2014, at 7:39 AM, Sean

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Jeremy Stanley
On 2014-09-12 11:36:20 -0400 (-0400), Mike Bayer wrote: [...] not to mention PYTHONHASHSEED only works on Python 3. What is the issue in tox you’re referring to ? Huh? The overrides we added to numerous projects' tox.ini files to stem the breakage in Python 2.x unit tests from hash seed

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Jeremy Stanley
On 2014-09-12 12:07:41 -0400 (-0400), Mike Bayer wrote: [...] corresponding to PYTHONHASHSEED, right? That whole thing is Python 3 only. See other reply, but I really don't understand where you got that idea. Yes Python 2.x does not randomize the hash seed by default like Py3K (you have to

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Jeremy Stanley
On 2014-09-12 17:16:11 +0100 (+0100), Daniel P. Berrange wrote: [...] Agreed, the problem with stale .pyc files is that it never occurs to developers that .pyc files are causing the problem until after you've wasted (potentially hours of) time debugging the problem. Avoiding this pain for all

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Chris Dent
On Fri, 12 Sep 2014, Julien Danjou wrote: I guess the problem is more likely that testrepository load the tests From the source directory whereas maybe we could make it load them from what's installed into the venv? This rather ruins TDD doesn't it? -- Chris Dent tw:@anticdent freenode:cdent

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Daniel P. Berrange
On Fri, Sep 12, 2014 at 04:23:09PM +, Jeremy Stanley wrote: On 2014-09-12 17:16:11 +0100 (+0100), Daniel P. Berrange wrote: [...] Agreed, the problem with stale .pyc files is that it never occurs to developers that .pyc files are causing the problem until after you've wasted

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Mike Bayer
On Sep 12, 2014, at 12:13 PM, Jeremy Stanley fu...@yuggoth.org wrote: On 2014-09-12 11:36:20 -0400 (-0400), Mike Bayer wrote: [...] not to mention PYTHONHASHSEED only works on Python 3. What is the issue in tox you’re referring to ? Huh? The overrides we added to numerous projects'

Re: [openstack-dev] [all] PYTHONDONTWRITEBYTECODE=true in tox.ini

2014-09-12 Thread Mike Bayer
On Sep 12, 2014, at 12:29 PM, Daniel P. Berrange berra...@redhat.com wrote: On Fri, Sep 12, 2014 at 04:23:09PM +, Jeremy Stanley wrote: On 2014-09-12 17:16:11 +0100 (+0100), Daniel P. Berrange wrote: [...] Agreed, the problem with stale .pyc files is that it never occurs to developers