-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Improvements to blocker handling in fine-grained incremental mode, etc. #4292
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
These are useful with fine-grained incremental mode.
Make order of processing files more predictable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LG, just two nits.
mypy/server/update.py
Outdated
('remaining', List[Tuple[str, str]])]) | ||
|
||
# The result of update_single_isolated when there is a blocking error. Items | ||
# are similar to NormalUpdate (but there are fewer). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if it makes sense to move remaining up in the list for NormalUpdate so that the first three items always have the same meaning?
mypy/server/update.py
Outdated
@@ -316,7 +372,9 @@ def delete_module(module_id: str, | |||
# TODO: Deletion of a package | |||
# TODO: Remove deps for the module (this only affects memory use, not correctness) | |||
new_graph = graph.copy() | |||
del new_graph[module_id] | |||
if module_id in new_graph: | |||
# TODO: Why would this ever be reached? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if you replace it with assert module_id not in new_graph
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Go ahead and merge when you're ready.
Handle various additional cases of blocking errors. This also contains a fair
amount of refactoring.