Issue with a dictionary and a get function #1473
Unanswered
Sanchoyzer
asked this question in
Q&A
Replies: 1 comment 2 replies
-
This is an interesting example. There was a change a few months ago that propagated narrowed types to nested functions: python/mypy#15133 (fixing python/mypy#2608) Perhaps lambdas were not covered there? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
There is an error:
error: Item "None" of "dict[Any, Any] | None" has no attribute "get" [union-attr]
. It looks a little bit strange because I've created a check for the 'None' case. What should I do to fix it?P.S.
mypy==1.5.1
,Python 3.11.4
Beta Was this translation helpful? Give feedback.
All reactions