Skip to content

Commit

Permalink
Add regression test TypedDict not-callable (#4717)
Browse files Browse the repository at this point in the history
  • Loading branch information
cdce8p authored Jul 19, 2021
1 parent bf493bb commit f437752
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ Release date: TBA

Closes #3525

* Fix false-positive ``not-callable`` with alternative ``TypedDict`` syntax

Closes #4715

* Clarify documentation for consider-using-from-import

* Don't emit ``unreachable`` warning for empty generator functions
Expand Down
6 changes: 6 additions & 0 deletions tests/functional/t/typedDict.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,9 @@ class CustomTD3(CustomTD2):
my_dict = CustomTD(var=1)
my_dict["var"]
my_dict["var"] = 2


# https://github.com/PyCQA/pylint/issues/4715
# Instance of TypedDict should be callable
Link = TypedDict("Link", {"href": str})
Link(href="foo")

0 comments on commit f437752

Please sign in to comment.