Return type for get_child_by_id
and get_widget_by_id
#1237
-
Loving the new |
Beta Was this translation helpful? Give feedback.
Answered by
willmcgugan
Nov 20, 2022
Replies: 1 comment 2 replies
-
We should do something similar to query, where you pass on the type and it validates it at runtime and statically. In the meantime try an |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
aaronst
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We should do something similar to query, where you pass on the type and it validates it at runtime and statically.
In the meantime try an
assert isinstance(widget, MyWidget)
to quell PyLance.