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
). A comment says this is for autocompletion support.
However, these type annotations are incorrect as the class has attributes that contain types (subclasses of JsonAPiResource), not instances. This leads type checkers to show incorrect errors when these attributes are used.
To fix, the code should have lines of the form type[JsonApiResource] instead, indicating that the attributes contain types, not instances.
The text was updated successfully, but these errors were encountered:
JelleZijlstra
added a commit
to JelleZijlstra/transifex-python
that referenced
this issue
Oct 30, 2024
The
transifex.api.TransifexApi
contains a number of lines of the formTeam: JsonApiResource
(transifex-python/transifex/api/__init__.py
Line 76 in 82ac996
However, these type annotations are incorrect as the class has attributes that contain types (subclasses of JsonAPiResource), not instances. This leads type checkers to show incorrect errors when these attributes are used.
To fix, the code should have lines of the form
type[JsonApiResource]
instead, indicating that the attributes contain types, not instances.The text was updated successfully, but these errors were encountered: