File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -639,15 +639,16 @@ def _run_once(self):
639639 event_list = self ._selector .select (timeout )
640640 dt = time .perf_counter () - t0
641641 dt_monotonic = time .monotonic () - t0_monotonic
642- if not event_list and timeout and dt < timeout :
642+ if (not event_list and timeout
643+ and (dt < timeout or dt_monotonic < timeout )):
643644 selector = self ._selector .__class__ .__name__
644645 if (selector .startswith (("Poll" , "Epoll" , "Iocp" ))
645646 or timeout > 1e-3 or dt > 1e-3 ):
646647 unit , factor = "ms" , 1e3
647648 else :
648649 unit , factor = "us" , 1e6
649- print ("asyncio: %s.select(%.3f %s) took %.3f %s"
650- " (monotonic: %.3f %s, clock res: %.3f %s)"
650+ print ("asyncio: %s.select(%.4f %s) took %.3f %s"
651+ " (monotonic= %.3f %s, clock res= %.3f %s)"
651652 % (self ._selector .__class__ .__name__ ,
652653 timeout * factor , unit ,
653654 dt * factor , unit ,
You can’t perform that action at this time.
0 commit comments