-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feat: add initial support for
TypedDict
`TypedDicts` are used only within the type system for analysis and represent the keys of a dictionary and their corresponding types. They are a useful tool when providing type hints of a JSON payload or similar. For example the following code snippet will raise a false-positive alert from this flake8 plug-in: ```python class ApiPage(TypedDict): url: str next: str data: list[dict[str, Any]] ``` This is because a `TypedDict` is analysed as if it was a standard class. Since it is only used in the type system it is safe to ignore anything that inherits from `TypedDict` in this plugin.
- Loading branch information
1 parent
5484162
commit ab939c7
Showing
2 changed files
with
77 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
This file contains 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