[openstack-dev] [testing] moving testrepository *outside* the tox venv
mtreinish at kortar.org
Sat Jul 11 00:01:31 UTC 2015
On Thu, Jul 09, 2015 at 06:59:44AM -0700, Morgan Fainberg wrote:
> Or a database per python major version (or at least gracefully handle the incompatibility).
> Sent via mobile
> > On Jul 9, 2015, at 06:43, Doug Hellmann <doug at doughellmann.com> wrote:
> > Excerpts from Robert Collins's message of 2015-07-09 10:37:17 +1200:
> >> I don't remember if this has previously been discussed, but as our
> >> Python3 readiness increases folk are going to feel pain from testr due
> >> to a silly Python 2/3 incompatibility around dbm files.
> >> https://bugs.launchpad.net/testrepository/+bug/1212909
> >> OpenStack (alone in the universe as far as I can tell) installs
> >> testrepository *inside* a tox venv. This then causes the timing
> >> database to be Python version specific. It also causes the test venv
> >> to suck in any dependencies testr might add.
> >> But testrepository is like tox- its meant to be installed systemwide
> >> (or at least in its own venv) and then just used to *run* test runners
> >> within whatever context.
> >> So - I'm looking to:
> >> A) have a discussion and identify any issues with moving testr out of
> >> the venvs. (Note: this doesn't mean stop using it, just removing it
> >> from test-requirements.txt, in the same way that tox isn't in
> >> test-requirements.txt).
> >> B) Capture that in a spec if its non-trivial.
> >> C) find volunteers to make it happen.
> > How much work would it be to make testrepository use a database format
> > that would be the same under all versions of python?
> > Doug
My long term plan (for almost a year now :( ) to do this was to add a new
repository type for testrepository that leverages subunit2sql. We could then
just use a local sqlite database to track the results which would avoid the
dbm compat issues and also expose a much more feature rich interface to use
the stored data.
The current blocker for this right now is sqlite support in subunit2sql. 
Some of the alembic migrations do not work on sqlite, and I haven't really had
a chance to work on fixing this. If someone was willing to help me on this that
would make this move a lot faster.
 We could start work on adding the new repository type now, but to use it
would would require a mysql or postgres db which is too heavyweight to be really
useful for most use cases
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 819 bytes
Desc: not available
More information about the OpenStack-dev