Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[dmypy] sort list of files for update by extension (#17245)
dmypy receives the list of updated files via `--update` flag. If this list contains both `foo.py` and `foo.pyi`, the order matters. It seems to process the first file in the list first. But if we have a `.pyi` file, we want this to be processed first since this one contains the typing information. Let's reverse sort the list of updated files by the extension. This should be a simple enough fix to resolve this. Though there might be some edge cases where the list of files to update contains just pyi files, but we might need to recheck the equivalent py files even if not explicitly updated.
- Loading branch information