scheduler.py

changeset 55
407af23d16bb
parent 54
cfcaa5f6ba33
child 59
8d0a815022cc
equal deleted inserted replaced
54:cfcaa5f6ba33 55:407af23d16bb
111 self._cond.wait(timeout) 111 self._cond.wait(timeout)
112 now = time.monotonic() 112 now = time.monotonic()
113 113
114 while self._list and self._list.when <= now: 114 while self._list and self._list.when <= now:
115 ev=self._list 115 ev=self._list
116 logger.info("%s: Scheduling event %s" % self.name(), str(ev.name)) 116 logger.debug("Scheduling event %s" % (ev.name or "(unknown)"))
117 # We are only allowed to remove ev from list when ev.cond allows 117 # We are only allowed to remove ev from list when ev.cond allows
118 with ev.cond: 118 with ev.cond:
119 self._list=ev.next 119 self._list=ev.next
120 ev.unlink() 120 ev.unlink()
121 ev.cond.notifyAll() 121 ev.cond.notifyAll()

mercurial