class documentation

class WatchmanReloader(BaseReloader): (source)

View In Hierarchy

Undocumented

Class Method check_availability Undocumented
Method __init__ Undocumented
Method check_server_status Return True if the server is available.
Method request_processed Undocumented
Method stop Undocumented
Method tick 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.
Method update_watches Undocumented
Method watched_roots Undocumented
Instance Variable client_timeout Undocumented
Instance Variable processed_request Undocumented
Instance Variable roots Undocumented
Property client Undocumented
Method _check_subscription Undocumented
Method _get_clock Undocumented
Method _subscribe Undocumented
Method _subscribe_dir Undocumented
Method _update_watches Undocumented
Method _watch_glob Watch a directory with a specific glob. If the directory doesn't yet exist, attempt to watch the parent directory and amend the patterns to include this. It's important this method isn't called more than one per directory when updating all subscriptions...
Method _watch_root Undocumented

Inherited from BaseReloader:

Method notify_file_changed Undocumented
Method run Undocumented
Method run_loop Undocumented
Method wait_for_apps_ready 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.
Method watch_dir Undocumented
Method watched_files Yield all files that need to be watched, including module files and files within globs.
Instance Variable directory_globs Undocumented
Instance Variable extra_files Undocumented
Property should_stop Undocumented
Instance Variable _stop_condition Undocumented
def __init__(self): (source)
def check_server_status(self, inner_ex=None): (source)

Return True if the server is available.

def request_processed(self, **kwargs): (source)

Undocumented

def tick(self): (source)

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 update_watches(self): (source)

Undocumented

def watched_roots(self, watched_files): (source)

Undocumented

client_timeout = (source)

Undocumented

processed_request = (source)

Undocumented

Undocumented

Undocumented

def _check_subscription(self, sub): (source)

Undocumented

@functools.lru_cache
def _get_clock(self, root): (source)

Undocumented

def _subscribe(self, directory, name, expression): (source)

Undocumented

def _subscribe_dir(self, directory, filenames): (source)

Undocumented

def _update_watches(self): (source)

Undocumented

def _watch_glob(self, directory, patterns): (source)

Watch a directory with a specific glob. If the directory doesn't yet exist, attempt to watch the parent directory and amend the patterns to include this. It's important this method isn't called more than one per directory when updating all subscriptions. Subsequent calls will overwrite the named subscription, so it must include all possible glob expressions.

def _watch_root(self, root): (source)

Undocumented