class documentation

class BaseReloader:

Known subclasses: django.utils.autoreload.StatReloader, django.utils.autoreload.WatchmanReloader

View In Hierarchy

Undocumented

Class Method check​_availability Undocumented
Method __init__ Undocumented
Method notify​_file​_changed Undocumented
Method run Undocumented
Method run​_loop Undocumented
Method stop Undocumented
Method tick No summary
Method wait​_for​_apps​_ready No summary
Method watch​_dir Undocumented
Method watched​_files Yield all files that need to be watched, including module files and files within globs.
Instance Variable ​_stop​_condition Undocumented
Instance Variable directory​_globs Undocumented
Instance Variable extra​_files Undocumented
Property should​_stop Undocumented
@classmethod
def check_availability(cls):
def __init__(self):

Undocumented

def notify_file_changed(self, path):

Undocumented

def run(self, django_main_thread):

Undocumented

def run_loop(self):

Undocumented

def stop(self):

Undocumented

def tick(self):
This generator is called in a loop from run_loop. It's important that the method takes care of pausing or otherwise waiting for a period of time. This split between run_loop() and tick() is to improve the testability of the reloader implementations by decoupling the work they do from the loop.
def wait_for_apps_ready(self, app_reg, django_main_thread):

Wait until Django reports that the apps have been loaded. If the given thread has terminated before the apps are ready, then a SyntaxError or other non-recoverable error has been raised. In that case, stop waiting for the apps_ready event and continue processing.

Return True if the thread is alive and the ready event has been triggered, or False if the thread is terminated while waiting for the event.

def watch_dir(self, path, glob):

Undocumented

def watched_files(self, include_globs=True):
Yield all files that need to be watched, including module files and files within globs.
_stop_condition =

Undocumented

directory_globs =

Undocumented

extra_files: set =

Undocumented

@property
should_stop =

Undocumented