Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e98a87f

Browse files
authored
Trim pytype_exclude_list. (#10208)
* Updates pytype to latest version. * Removes files from pytype_exclude_list that can now be parsed.
1 parent 185adf0 commit e98a87f

2 files changed

Lines changed: 3 additions & 182 deletions

File tree

requirements-tests.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ packaging==23.1
1010
pathspec>=0.10.3
1111
pre-commit-hooks==4.4.0 # must match .pre-commit-config.yaml
1212
pycln==2.1.3 # must match .pre-commit-config.yaml
13-
pytype==2023.4.27; platform_system != "Windows" and python_version < "3.11"
13+
pytype==2023.5.24; platform_system != "Windows" and python_version < "3.11"
1414
pyyaml==6.0
1515
stubdefaulter==0.1.0
1616
termcolor>=2.3

tests/pytype_exclude_list.txt

Lines changed: 2 additions & 181 deletions
Original file line numberDiff line numberDiff line change
@@ -13,186 +13,7 @@ stubs/mysqlclient/MySQLdb/cursors.pyi
1313
# twisted not installed during tests
1414
stubs/pika/pika/adapters/twisted_connection.pyi
1515

16-
# _pb2.pyi have some constructs that break pytype
17-
# Eg
18-
# pytype.pyi.parser.ParseError: File: "/Users/nipunn/src/typeshed/third_party/2and3/google/protobuf/descriptor_pb2.pyi", line 195
19-
# b"TypeValue = typing___NewType('TypeValue', builtin___int)"
20-
stubs/protobuf/google/protobuf/any_pb2.pyi
21-
stubs/protobuf/google/protobuf/api_pb2.pyi
22-
stubs/protobuf/google/protobuf/compiler/plugin_pb2.pyi
23-
stubs/protobuf/google/protobuf/descriptor.pyi
24-
stubs/protobuf/google/protobuf/descriptor_pb2.pyi
25-
stubs/protobuf/google/protobuf/duration_pb2.pyi
26-
stubs/protobuf/google/protobuf/empty_pb2.pyi
27-
stubs/protobuf/google/protobuf/field_mask_pb2.pyi
28-
stubs/protobuf/google/protobuf/internal/containers.pyi
29-
stubs/protobuf/google/protobuf/internal/decoder.pyi
30-
stubs/protobuf/google/protobuf/internal/encoder.pyi
31-
stubs/protobuf/google/protobuf/internal/enum_type_wrapper.pyi
32-
stubs/protobuf/google/protobuf/internal/extension_dict.pyi
33-
stubs/protobuf/google/protobuf/internal/well_known_types.pyi
34-
stubs/protobuf/google/protobuf/json_format.pyi
35-
stubs/protobuf/google/protobuf/message.pyi
36-
stubs/protobuf/google/protobuf/message_factory.pyi
37-
stubs/protobuf/google/protobuf/service.pyi
38-
stubs/protobuf/google/protobuf/source_context_pb2.pyi
39-
stubs/protobuf/google/protobuf/struct_pb2.pyi
40-
stubs/protobuf/google/protobuf/symbol_database.pyi
41-
stubs/protobuf/google/protobuf/text_format.pyi
42-
stubs/protobuf/google/protobuf/timestamp_pb2.pyi
43-
stubs/protobuf/google/protobuf/type_pb2.pyi
44-
stubs/protobuf/google/protobuf/wrappers_pb2.pyi
45-
46-
stubs/tensorflow/tensorflow/compiler/xla/service/hlo_pb2.pyi
47-
stubs/tensorflow/tensorflow/compiler/xla/xla_data_pb2.pyi
48-
stubs/tensorflow/tensorflow/core/example/example_parser_configuration_pb2.pyi
49-
stubs/tensorflow/tensorflow/core/example/example_pb2.pyi
50-
stubs/tensorflow/tensorflow/core/example/feature_pb2.pyi
51-
stubs/tensorflow/tensorflow/core/framework/allocation_description_pb2.pyi
52-
stubs/tensorflow/tensorflow/core/framework/api_def_pb2.pyi
53-
stubs/tensorflow/tensorflow/core/framework/attr_value_pb2.pyi
54-
stubs/tensorflow/tensorflow/core/framework/cost_graph_pb2.pyi
55-
stubs/tensorflow/tensorflow/core/framework/dataset_metadata_pb2.pyi
56-
stubs/tensorflow/tensorflow/core/framework/dataset_options_pb2.pyi
57-
stubs/tensorflow/tensorflow/core/framework/device_attributes_pb2.pyi
58-
stubs/tensorflow/tensorflow/core/framework/full_type_pb2.pyi
59-
stubs/tensorflow/tensorflow/core/framework/function_pb2.pyi
60-
stubs/tensorflow/tensorflow/core/framework/graph_pb2.pyi
61-
stubs/tensorflow/tensorflow/core/framework/graph_transfer_info_pb2.pyi
62-
stubs/tensorflow/tensorflow/core/framework/kernel_def_pb2.pyi
63-
stubs/tensorflow/tensorflow/core/framework/log_memory_pb2.pyi
64-
stubs/tensorflow/tensorflow/core/framework/model_pb2.pyi
65-
stubs/tensorflow/tensorflow/core/framework/node_def_pb2.pyi
66-
stubs/tensorflow/tensorflow/core/framework/op_def_pb2.pyi
67-
stubs/tensorflow/tensorflow/core/framework/reader_base_pb2.pyi
68-
stubs/tensorflow/tensorflow/core/framework/resource_handle_pb2.pyi
69-
stubs/tensorflow/tensorflow/core/framework/step_stats_pb2.pyi
70-
stubs/tensorflow/tensorflow/core/framework/summary_pb2.pyi
71-
stubs/tensorflow/tensorflow/core/framework/tensor_description_pb2.pyi
72-
stubs/tensorflow/tensorflow/core/framework/tensor_pb2.pyi
73-
stubs/tensorflow/tensorflow/core/framework/tensor_shape_pb2.pyi
74-
stubs/tensorflow/tensorflow/core/framework/tensor_slice_pb2.pyi
75-
stubs/tensorflow/tensorflow/core/framework/types_pb2.pyi
76-
stubs/tensorflow/tensorflow/core/framework/variable_pb2.pyi
77-
stubs/tensorflow/tensorflow/core/framework/versions_pb2.pyi
78-
stubs/tensorflow/tensorflow/core/protobuf/bfc_memory_map_pb2.pyi
79-
stubs/tensorflow/tensorflow/core/protobuf/cluster_pb2.pyi
80-
stubs/tensorflow/tensorflow/core/protobuf/composite_tensor_variant_pb2.pyi
81-
stubs/tensorflow/tensorflow/core/protobuf/config_pb2.pyi
82-
stubs/tensorflow/tensorflow/core/protobuf/control_flow_pb2.pyi
83-
stubs/tensorflow/tensorflow/core/protobuf/coordination_config_pb2.pyi
84-
stubs/tensorflow/tensorflow/core/protobuf/core_platform_payloads_pb2.pyi
85-
stubs/tensorflow/tensorflow/core/protobuf/data_service_pb2.pyi
86-
stubs/tensorflow/tensorflow/core/protobuf/debug_event_pb2.pyi
87-
stubs/tensorflow/tensorflow/core/protobuf/debug_pb2.pyi
88-
stubs/tensorflow/tensorflow/core/protobuf/device_filters_pb2.pyi
89-
stubs/tensorflow/tensorflow/core/protobuf/device_properties_pb2.pyi
90-
stubs/tensorflow/tensorflow/core/protobuf/distributed_runtime_payloads_pb2.pyi
91-
stubs/tensorflow/tensorflow/core/protobuf/error_codes_pb2.pyi
92-
stubs/tensorflow/tensorflow/core/protobuf/fingerprint_pb2.pyi
93-
stubs/tensorflow/tensorflow/core/protobuf/graph_debug_info_pb2.pyi
94-
stubs/tensorflow/tensorflow/core/protobuf/meta_graph_pb2.pyi
95-
stubs/tensorflow/tensorflow/core/protobuf/named_tensor_pb2.pyi
96-
stubs/tensorflow/tensorflow/core/protobuf/queue_runner_pb2.pyi
97-
stubs/tensorflow/tensorflow/core/protobuf/remote_tensor_handle_pb2.pyi
98-
stubs/tensorflow/tensorflow/core/protobuf/rewriter_config_pb2.pyi
99-
stubs/tensorflow/tensorflow/core/protobuf/saved_model_pb2.pyi
100-
stubs/tensorflow/tensorflow/core/protobuf/saved_object_graph_pb2.pyi
101-
stubs/tensorflow/tensorflow/core/protobuf/saver_pb2.pyi
102-
stubs/tensorflow/tensorflow/core/protobuf/service_config_pb2.pyi
103-
stubs/tensorflow/tensorflow/core/protobuf/snapshot_pb2.pyi
104-
stubs/tensorflow/tensorflow/core/protobuf/struct_pb2.pyi
105-
stubs/tensorflow/tensorflow/core/protobuf/tensor_bundle_pb2.pyi
106-
stubs/tensorflow/tensorflow/core/protobuf/tensorflow_server_pb2.pyi
107-
stubs/tensorflow/tensorflow/core/protobuf/tpu/compilation_result_pb2.pyi
108-
stubs/tensorflow/tensorflow/core/protobuf/tpu/dynamic_padding_pb2.pyi
109-
stubs/tensorflow/tensorflow/core/protobuf/tpu/optimization_parameters_pb2.pyi
110-
stubs/tensorflow/tensorflow/core/protobuf/tpu/topology_pb2.pyi
111-
stubs/tensorflow/tensorflow/core/protobuf/tpu/tpu_embedding_configuration_pb2.pyi
112-
stubs/tensorflow/tensorflow/core/protobuf/trackable_object_graph_pb2.pyi
113-
stubs/tensorflow/tensorflow/core/protobuf/transport_options_pb2.pyi
114-
stubs/tensorflow/tensorflow/core/protobuf/verifier_config_pb2.pyi
115-
stubs/tensorflow/tensorflow/core/util/event_pb2.pyi
116-
stubs/tensorflow/tensorflow/core/util/memmapped_file_system_pb2.pyi
117-
stubs/tensorflow/tensorflow/core/util/saved_tensor_slice_pb2.pyi
118-
stubs/tensorflow/tensorflow/core/util/test_log_pb2.pyi
119-
stubs/tensorflow/tensorflow/python/keras/protobuf/projector_config_pb2.pyi
120-
stubs/tensorflow/tensorflow/python/keras/protobuf/saved_metadata_pb2.pyi
121-
stubs/tensorflow/tensorflow/python/keras/protobuf/versions_pb2.pyi
122-
stubs/tensorflow/tensorflow/tsl/protobuf/error_codes_pb2.pyi
123-
stubs/tensorflow/tensorflow/tsl/protobuf/histogram_pb2.pyi
124-
125-
# pytype doesn't support inner classes properly
126-
stubs/SQLAlchemy/sqlalchemy/databases/__init__.pyi
127-
stubs/SQLAlchemy/sqlalchemy/dialects/__init__.pyi
128-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/__init__.pyi
129-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/base.pyi
130-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/information_schema.pyi
131-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/json.pyi
132-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/mxodbc.pyi
133-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/pymssql.pyi
134-
stubs/SQLAlchemy/sqlalchemy/dialects/mssql/pyodbc.pyi
135-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/__init__.pyi
136-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/aiomysql.pyi
137-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/asyncmy.pyi
138-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/base.pyi
139-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/cymysql.pyi
140-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/dml.pyi
141-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/expression.pyi
142-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/json.pyi
143-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/mariadb.pyi
144-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/mariadbconnector.pyi
145-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/mysqlconnector.pyi
146-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/mysqldb.pyi
147-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/oursql.pyi
148-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/pymysql.pyi
149-
stubs/SQLAlchemy/sqlalchemy/dialects/mysql/pyodbc.pyi
150-
stubs/SQLAlchemy/sqlalchemy/dialects/oracle/base.pyi
151-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/__init__.pyi
152-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/array.pyi
153-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/asyncpg.pyi
154-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/base.pyi
155-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/dml.pyi
156-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/ext.pyi
157-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/hstore.pyi
158-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/json.pyi
159-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/pg8000.pyi
160-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/psycopg2.pyi
161-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/psycopg2cffi.pyi
162-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/pygresql.pyi
163-
stubs/SQLAlchemy/sqlalchemy/dialects/postgresql/ranges.pyi
164-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/__init__.pyi
165-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/aiosqlite.pyi
166-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/base.pyi
167-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/dml.pyi
168-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/json.pyi
169-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/pysqlcipher.pyi
170-
stubs/SQLAlchemy/sqlalchemy/dialects/sqlite/pysqlite.pyi
171-
stubs/SQLAlchemy/sqlalchemy/engine/cursor.pyi
172-
stubs/SQLAlchemy/sqlalchemy/engine/result.pyi
173-
stubs/SQLAlchemy/sqlalchemy/engine/row.pyi
174-
stubs/SQLAlchemy/sqlalchemy/ext/asyncio/result.pyi
175-
stubs/SQLAlchemy/sqlalchemy/ext/horizontal_shard.pyi
176-
stubs/SQLAlchemy/sqlalchemy/orm/attributes.pyi
177-
stubs/SQLAlchemy/sqlalchemy/orm/descriptor_props.pyi
178-
stubs/SQLAlchemy/sqlalchemy/orm/dynamic.pyi
179-
stubs/SQLAlchemy/sqlalchemy/orm/mapper.pyi
180-
stubs/SQLAlchemy/sqlalchemy/orm/query.pyi
181-
stubs/SQLAlchemy/sqlalchemy/orm/strategy_options.pyi
182-
stubs/SQLAlchemy/sqlalchemy/orm/util.pyi
183-
stubs/SQLAlchemy/sqlalchemy/sql/compiler.pyi
184-
stubs/SQLAlchemy/sqlalchemy/sql/crud.pyi
185-
stubs/SQLAlchemy/sqlalchemy/sql/ddl.pyi
186-
stubs/SQLAlchemy/sqlalchemy/sql/elements.pyi
187-
stubs/SQLAlchemy/sqlalchemy/sql/functions.pyi
188-
stubs/SQLAlchemy/sqlalchemy/sql/lambdas.pyi
189-
stubs/SQLAlchemy/sqlalchemy/sql/schema.pyi
190-
stubs/SQLAlchemy/sqlalchemy/sql/selectable.pyi
191-
stubs/Flask-SQLAlchemy/flask_sqlalchemy/__init__.pyi
192-
stubs/Flask-SQLAlchemy/flask_sqlalchemy/model.pyi
193-
stubs/Flask-SQLAlchemy/flask_sqlalchemy/utils.pyi
194-
195-
# Uncertain why pytype is giving an error
196-
# pytype.pytd.visitors.ContainerError
16+
# pytype.pytd.visitors.ContainerError: Conflicting values for TypeVar
19717
stubs/openpyxl/openpyxl/descriptors/nested.pyi
18+
stubs/SQLAlchemy/sqlalchemy/engine/row.pyi
19819
stubs/SQLAlchemy/sqlalchemy/sql/annotation.pyi

0 commit comments

Comments
 (0)