[Twisted-Python] Re: [Twisted-commits] r15230 - Merge of jml/trial-deferred-logic -r15183:15229. Resolves #1341.
![](https://secure.gravatar.com/avatar/7ed9784cbb1ba1ef75454034b3a8e6a1.jpg?s=120&d=mm&r=g)
On Sun, 27 Nov 2005 23:35:45 -0700, Jonathan Lange <jml@wolfwood.twistedmatrix.com> wrote:
The Gtk reactor can no longer complete the test suite: http://twistedmatrix.com/buildbot/reactors/builds/884/step-gtk/0 On my machine, the suite hangs in twisted.web.test.test_webclient.CookieTestCase.testNoCookies, but it seems to die in twisted.test.test_tcp.HalfClose2TestCase.testNoNotification on buildbot every time. This may just be a race (or several races) going different ways on a somewhat reliable fashion on the different hardware. It seems like the remaining reactor.iterate() calls are the likely cause of this? Jean-Paul
![](https://secure.gravatar.com/avatar/1327ce755b24b956995d68accae3eab2.jpg?s=120&d=mm&r=g)
On 29/11/05, Jean-Paul Calderone <exarkun@divmod.com> wrote:
For the record, the branch has been reverted, and I'm working on fixing the hanging tests. The problems *so far* appear to be caused by reactor.runUntilCurrent being re-entered. Not certain that they are race conditions. The difference in results may be due to running the tests in different orders. Perhaps runUntilCurrent should check for re-entry and raise some sort of exception? If you maintain code in Twisted, even nominally, then *now* is the time to start cleaning up your tests. Calls to reactor.iterate, util.spinUntil, util.spinWhile and util.wait from within tests cannot be supported if Trial is ever going to behave sanely.[1] If you are uncertain, check the tracker. cheers, jml [1] As I understand it. I am no reactrologist.
![](https://secure.gravatar.com/avatar/d6328babd9f9a98ecc905e1ccac2495e.jpg?s=120&d=mm&r=g)
On Wed, 30 Nov 2005 13:09:30 +1100, Jonathan Lange <jml@mumak.net> wrote:
If you maintain code in Twisted, even nominally, then *now* is the time to start cleaning up your tests.
everybody: DO IT. DO IT NOW. jml: any particular, tricky tests you want a hand cleaning up? I will try to put some effort towards this.
As chief reactrologister I can officially confirm that your understanding is exactly 100% totally and completely correct. There are no sensible semantics for a re-entrant reactor.
![](https://secure.gravatar.com/avatar/1327ce755b24b956995d68accae3eab2.jpg?s=120&d=mm&r=g)
On 30/11/05, glyph@divmod.com <glyph@divmod.com> wrote:
Off the top of my head: - The conch tests are impenetrable (really, z3p needs to fix them) - twisted.protocols.loopback uses spinWhile and spinUntil. I'm not game to fix that. - The test_tcp tests that Jp commented on in a different post ;) If anyone is curious, the bugs are all tagged 'tests' and can be found at http://www.twistedmatrix.com/bugs/. Phillipe will hug whoever fixes the most tests. jml
![](https://secure.gravatar.com/avatar/1327ce755b24b956995d68accae3eab2.jpg?s=120&d=mm&r=g)
On 29/11/05, Jean-Paul Calderone <exarkun@divmod.com> wrote:
For the record, the branch has been reverted, and I'm working on fixing the hanging tests. The problems *so far* appear to be caused by reactor.runUntilCurrent being re-entered. Not certain that they are race conditions. The difference in results may be due to running the tests in different orders. Perhaps runUntilCurrent should check for re-entry and raise some sort of exception? If you maintain code in Twisted, even nominally, then *now* is the time to start cleaning up your tests. Calls to reactor.iterate, util.spinUntil, util.spinWhile and util.wait from within tests cannot be supported if Trial is ever going to behave sanely.[1] If you are uncertain, check the tracker. cheers, jml [1] As I understand it. I am no reactrologist.
![](https://secure.gravatar.com/avatar/d6328babd9f9a98ecc905e1ccac2495e.jpg?s=120&d=mm&r=g)
On Wed, 30 Nov 2005 13:09:30 +1100, Jonathan Lange <jml@mumak.net> wrote:
If you maintain code in Twisted, even nominally, then *now* is the time to start cleaning up your tests.
everybody: DO IT. DO IT NOW. jml: any particular, tricky tests you want a hand cleaning up? I will try to put some effort towards this.
As chief reactrologister I can officially confirm that your understanding is exactly 100% totally and completely correct. There are no sensible semantics for a re-entrant reactor.
![](https://secure.gravatar.com/avatar/1327ce755b24b956995d68accae3eab2.jpg?s=120&d=mm&r=g)
On 30/11/05, glyph@divmod.com <glyph@divmod.com> wrote:
Off the top of my head: - The conch tests are impenetrable (really, z3p needs to fix them) - twisted.protocols.loopback uses spinWhile and spinUntil. I'm not game to fix that. - The test_tcp tests that Jp commented on in a different post ;) If anyone is curious, the bugs are all tagged 'tests' and can be found at http://www.twistedmatrix.com/bugs/. Phillipe will hug whoever fixes the most tests. jml
participants (3)
-
glyph@divmod.com
-
Jean-Paul Calderone
-
Jonathan Lange