Skip to content

Commit

Permalink
Passes all the tests that the default reactor does.
Browse files Browse the repository at this point in the history
The key was making test_internet work (thanks therve).  It exposed a
key problem with order dependencies for delayed calls vs. IO.  Now, it
runs correctly, just in 475s vs 190s for the select reactor.  Need to
figure out just why that is...
  • Loading branch information
ghtdak committed Mar 12, 2008
1 parent 9556fbc commit 70e7790
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions qt4reactor.py
Expand Up @@ -178,8 +178,8 @@ def iterate(self,delay=0.0):
if delay == 0.0: if delay == 0.0:
self.reactorInvokePrivate() self.reactorInvokePrivate()
self._timer.stop() self._timer.stop()
self.qApp.processEvents() #self.qApp.processEvents()
self._timer.start() #self._timer.start()
else: else:
endTime = delay + time.time() endTime = delay + time.time()
self.reactorInvokePrivate() self.reactorInvokePrivate()
Expand Down Expand Up @@ -221,10 +221,10 @@ def reactorInvokePrivate(self):
self._blockApp.quit() self._blockApp.quit()
self._doSomethingCount += 1 self._doSomethingCount += 1
self.runUntilCurrent() self.runUntilCurrent()
#self.qApp.processEvents()
t = self.timeout() t = self.timeout()
if t is None: t=0.1 if t is None: t=0.1
else: t = min(t,0.1) else: t = min(t,0.1)
self.qApp.processEvents()
self._timer.start(t*1010) self._timer.start(t*1010)


def doIteration(self): def doIteration(self):
Expand Down

0 comments on commit 70e7790

Please sign in to comment.