You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Don't shoot me, I am just the messenger!
I don't think this is a real issue, we know a "text" element which follows the XSD will be a str, and if falsely will get a replacement with Defaults.TYPE_DEFAULTS[str]; I wonder if there is a way to get pyright to realize this. BTW, pyright is from Microsoft so somehow I am holding you a bit responsible :p
I found the issue which was that Defaults.TYPE_DEFAULTS[str] itself was declared as Any since Defaults.TYPE_DEFAULTS holds the defaults for different data types hence the return type is Any. b679357 resolved this by wrapping Defaults.TYPE_DEFAULTS[str] with a str().
DataHelper.get_element_text
is supposed to always return astr
, but callsget_element
, which can returnNone
. Pyright is not happy.The text was updated successfully, but these errors were encountered: