test_doctest failing
Looks like Skip's r59137 fix for working with tracing has led to test_doctest to be broken on 2.5 and the trunk (at least according to the buildbots). Can someone either revert the commit or fix it? I would normally do it myself but US Thanksgiving has me tied up to not do too much beyond bitching about the amount of buildbot emails I have been getting. =) -Brett
Brett> Looks like Skip's r59137 fix for working with tracing has led to Brett> test_doctest to be broken on 2.5 and the trunk (at least Brett> according to the buildbots). Can someone either revert the Brett> commit or fix it? I would normally do it myself but US Brett> Thanksgiving has me tied up to not do too much beyond bitching Brett> about the amount of buildbot emails I have been getting. =) Sorry. I did verify that it solved the problem I was having with trace & doctest, but I completely forgot to make test after applying that patch. The checkins have been reverted. Skip
On Fri, Nov 23, 2007 at 10:32:25PM -0600, skip@pobox.com wrote: -> -> Brett> Looks like Skip's r59137 fix for working with tracing has led to -> Brett> test_doctest to be broken on 2.5 and the trunk (at least -> Brett> according to the buildbots). Can someone either revert the -> Brett> commit or fix it? I would normally do it myself but US -> Brett> Thanksgiving has me tied up to not do too much beyond bitching -> Brett> about the amount of buildbot emails I have been getting. =) -> -> Sorry. I did verify that it solved the problem I was having with trace & -> doctest, but I completely forgot to make test after applying that patch. -> The checkins have been reverted. Skip, this set_trace rewrite fixes the problem in both 25-maint and trunk: def set_trace(self, frame=None): self.__debugger_used = True if frame is None: frame = sys._getframe().f_back pdb.Pdb.set_trace(self, frame) from the old: def set_trace(self): self.__debugger_used = True pdb.Pdb.set_trace(self) This was an actual bug: the patch didn't correctly allow for the fact that Bdb.set_trace(self, None) went and got the calling frame -- which, when the function was overriden in a subclass, was the subclass function. Let me know if you want a formal patch or somethin'. And thanks for tackling the doctest/trace situation - some users have been complaining about it to me and it was on my list for tomorrow! Happy post-Thanksgiving, all! cheers, --titus
Titus> Skip, this set_trace rewrite fixes the problem in both 25-maint and Titus> trunk: ... Thanks, Titus. Both the doctest and trace tests pass with your change. Checked back in. I didn't run the full test suite, as test_sqlite causes a bus error on my Mac which I've yet to investigate. Titus> Let me know if you want a formal patch or somethin'. And thanks Titus> for tackling the doctest/trace situation - some users have been Titus> complaining about it to me and it was on my list for tomorrow! Actually, there was little tackling on my part. More like googling. I searched for "trace and doctest". The second hit was a patch against 2.4 from February 2006: http://bugs.python.org/issue1429818 I blindly applied the patches it contained, verified they solved the problems I was having, then checked it in. Again, my apologies to Brett and others for the buildbot breakage. Skip
On Nov 24, 2007 6:35 AM, <skip@pobox.com> wrote:
Thanks, Titus. Both the doctest and trace tests pass with your change. Checked back in. I didn't run the full test suite, as test_sqlite causes a bus error on my Mac which I've yet to investigate.
It's easy though to run all tests *except* a known failure: .../runtest.py -x test_sqline -- --Guido van Rossum (home page: http://www.python.org/~guido/)
On Sat, Nov 24, 2007 at 10:23:06AM -0800, Guido van Rossum wrote: -> On Nov 24, 2007 6:35 AM, <skip@pobox.com> wrote: -> > Thanks, Titus. Both the doctest and trace tests pass with your change. -> > Checked back in. I didn't run the full test suite, as test_sqlite causes a -> > bus error on my Mac which I've yet to investigate. -> -> It's easy though to run all tests *except* a known failure: -> .../runtest.py -x test_sqline Just to make sure ... do you mean regrtest? ./python Lib/test/regrtest.py -x test_sqlite ? (There's no 'runtest.py' in the trunk, and 'runtests.py' exists under Lib/ctypes/.) --titus
On Nov 24, 2007 1:57 PM, Titus Brown <titus@caltech.edu> wrote:
On Sat, Nov 24, 2007 at 10:23:06AM -0800, Guido van Rossum wrote: -> On Nov 24, 2007 6:35 AM, <skip@pobox.com> wrote: -> > Thanks, Titus. Both the doctest and trace tests pass with your change. -> > Checked back in. I didn't run the full test suite, as test_sqlite causes a -> > bus error on my Mac which I've yet to investigate. -> -> It's easy though to run all tests *except* a known failure: -> .../runtest.py -x test_sqline
Just to make sure ... do you mean regrtest?
./python Lib/test/regrtest.py -x test_sqlite
?
Yep, he means regrtest. I really need to write a "How to run and write unit test for Python and its Standard Library" some day. -Brett
participants (4)
-
Brett Cannon
-
Guido van Rossum
-
skip@pobox.com
-
Titus Brown