Open rchen152 opened 2 years ago
Update: we're also getting some odd error in involving sqlalchemy.types (https://github.com/google/pytype/issues/1240):
Couldn't import pyi for 'sqlalchemy.dialects.postgresql' [pyi-error] Can't find pyi for 'sqltypes.ARRAY', referenced from 'sqlalchemy.dialects.postgresql.array'
The sqlalchemy.dialects.postgresql.array stub contains:
import sqlalchemy.types as sqltypes
[...]
class ARRAY(sqltypes.ARRAY): ...
which is what I assume pytype is unhappy about. When I try running pytype over all the sqlalchemy stubs, I see lots of errors like this involving various sqlalchemy.types attributes.
Most of the pytype errors in the SQLAlchemy stubs have been fixed; two files are still on the exclude list due to a "conflicting values for TypeVar" error: https://github.com/python/typeshed/blob/2ec6ba979f98c3c49d3a7ac2b11f1b3459e8e95a/tests/pytype_exclude_list.txt#L18-L19.
See https://github.com/python/typeshed/pull/6585. There are two problems:
from ... import X
thanks to https://github.com/google/pytype/blob/002b88cf8e0254fbd73fa0277800ec1d0c4e9a99/pytype/pyi/parser.py#L61.