Type annotations - #162
Open
JulienPalard wants to merge 10 commits into
Open
Conversation
hugovk
reviewed
Jun 12, 2026
hugovk
left a comment
Collaborator
There was a problem hiding this comment.
It would be good to add a type checker to CI, which will probably need some more adjustments, but that can be a follow up.
Collaborator
Author
|
Thank you very much @hugovk for this review! I'll try to add a checker in the CI in another PR. |
Collaborator
Author
|
Hum, Windows... |
hugovk
approved these changes
Jun 28, 2026
| return os.cpu_count() or 1 | ||
| return max(int(values), 1) | ||
|
|
||
| def string_with_no_backslash(user_input): |
Collaborator
There was a problem hiding this comment.
Suggested change
| def string_with_no_backslash(user_input): | |
| def string_with_no_backslash(user_input: str) -> str: |
| if os.path.isfile(path): | ||
| if path in ignore_list: | ||
| if path.is_file(): | ||
| if str(path) in ignore_list: |
Collaborator
There was a problem hiding this comment.
Also use is_ignored() here so the path slashes are normalised, similar to the path branch below?
Suggested change
| if str(path) in ignore_list: | |
| if is_ignored(path, ignore_list):: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Spotted some files paths were passed as string instead of Path, while changing that I added a few annotations to disambiguate str vs Path, and did the rest.