Server for mypy daemon mode.
This implements a daemon process which keeps useful state in memory to enable fine-grained incremental reprocessing of changes.
Class | Server |
No class docstring; 0/9 instance variable, 17/27 methods documented |
Function | daemonize |
Create the daemon process via "dmypy daemon" and pass options via command line |
Function | filter_out_missing_top_level_packages |
Quickly filter out obviously missing top-level packages. |
Function | find_all_sources_in_build |
Undocumented |
Function | fix_module_deps |
After an incremental update, update module dependencies to reflect the new state. |
Function | get_meminfo |
Undocumented |
Function | ignore_suppressed_imports |
Can we skip looking for newly unsuppressed imports to module? |
Function | process_start_options |
Undocumented |
Constant | CONNECTION_NAME |
Undocumented |
Constant | MEM_PROFILE |
Undocumented |
Constant | MiB |
Undocumented |
Variable | ChangesAndRemovals |
Undocumented |
Variable | ModulePathPair |
Undocumented |
Variable | ModulePathPairs |
Undocumented |
Create the daemon process via "dmypy daemon" and pass options via command line
When creating the daemon grandchild, we create it in a new console, which is started hidden. We cannot use DETACHED_PROCESS since it will cause console windows to pop up when starting. See https://github.com/python/cpython/pull/4150#issuecomment-340215696 for more on why we can't have nice things.
It also pickles the options to be unpickled by mypy.
Parameters | |
options:Options | Undocumented |
status_file:str | Undocumented |
timeout:Optional[ | Undocumented |
log_file:Optional[ | Undocumented |
Returns | |
int | Undocumented |
Quickly filter out obviously missing top-level packages.
Return packages with entries that can't be found removed.
This is approximate: some packages that aren't actually valid may be included. However, all potentially valid packages must be returned.
Parameters | |
packages:Set[ | Undocumented |
search_paths:SearchPaths | Undocumented |
fscache:FileSystemCache | Undocumented |
Returns | |
Set[ | Undocumented |
Undocumented
Parameters | |
graph:mypy.build.Graph | Undocumented |
extra:Sequence[ | Undocumented |
Returns | |
List[ | Undocumented |
After an incremental update, update module dependencies to reflect the new state.
This can make some suppressed dependencies non-suppressed, and vice versa (if modules have been added to or removed from the build).
Parameters | |
graph:mypy.build.Graph | Undocumented |
Parameters | |
module:str | Undocumented |
Returns | |
bool | Undocumented |
Undocumented
Parameters | |
flags:List[ | Undocumented |
allow_sources:bool | Undocumented |
Returns | |
Options | Undocumented |