MCPcopy
hub / github.com/django/django / tick

Method tick

django/utils/autoreload.py:607–626  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

605 self.processed_request.set()
606
607 def tick(self):
608 request_finished.connect(self.request_processed)
609 self.update_watches()
610 while True:
611 if self.processed_request.is_set():
612 self.update_watches()
613 self.processed_request.clear()
614 try:
615 self.client.receive()
616 except pywatchman.SocketTimeout:
617 pass
618 except pywatchman.WatchmanError as ex:
619 logger.debug("Watchman error: %s, checking server status.", ex)
620 self.check_server_status(ex)
621 else:
622 for sub in list(self.client.subs.keys()):
623 self._check_subscription(sub)
624 yield
625 # Protect against busy loops.
626 time.sleep(0.1)
627
628 def stop(self):
629 self.client.close()

Callers

nothing calls this directly

Calls 10

update_watchesMethod · 0.95
check_server_statusMethod · 0.95
_check_subscriptionMethod · 0.95
is_setMethod · 0.80
sleepMethod · 0.80
connectMethod · 0.45
clearMethod · 0.45
receiveMethod · 0.45
debugMethod · 0.45
keysMethod · 0.45

Tested by

no test coverage detected