[prev in list] [next in list] [prev in thread] [next in thread]
List: python-distutils-sig
Subject: Re: [Distutils] buildout: bin/test --coverage
From: Thomas Lotze <thomas () thomas-lotze ! de>
Date: 2008-02-12 20:19:52
Message-ID: pan.2008.02.12.20.19.51.776699 () ID-174572 ! user ! uni-berlin ! de
[Download RAW message or body]
Marius Gedminas wrote:
> It's not a problem with the recipe, it's a problem with zope.testing, or,
Sorry, that should have been obvious to me. No idea what made me blame it
on the recipe...
> more fundamentally, with Python. The sys.settrace hook used to
> implement coverage tracing is non-recursive.
>
> zope.testing tests its own ability to do coverage tracing, and since the
> test is run in the same Python process as the test runner, the side
> effect of the test's calling sys.settrace is that the runner is no
> longer able to trace coverage.
Ah, this makes some sense since the function that was reported uncovered
after the change is tested later in the same doc test.
> list(obj) cals obj.__len__ as an optimization. This results in an
> infinite recursive loop, but then list(obj) traps that, hides it, and
> does the brute-force list conversion. As a side effect of sys.settrace,
> the stack overflow RuntimeError happens inside the tracing hook and
> Python removes it for misbehaving. Tracing stops from that point on.
That's what I call gory details...
> Python's doctest also had side effects that used to disable tracing.
OK, so it's no longer a subject for this list at least.
--
Thomas
_______________________________________________
Distutils-SIG maillist - Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic