Replies: 1 comment
-
This seems like a better fit for a type checker like ty or at least a future type-aware linter. I don't think ty has any existing rules to require a narrower type than |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm interested for a rule that warns me when an unknown dict value is affected to a variable, like this:
Using
dict[str, Any]
is pretty common for me. For my experience, it usually doesn't mean that all the items of the dictionary have an unknown type, but it usually means that the dictionary is untyped (expect for the keys): in many cases, I known the type of the item.A rule that warns me when I'm able to type a variable could help me to improve typing in my projects.
Beta Was this translation helpful? Give feedback.
All reactions