fix: fix type hint union with grpc enum with old protobuf (#1157)

* fix: fix type hint union with grpc enum with old protobuf

* fix: add type ignore
This commit is contained in:
George
2026-03-10 13:44:54 +07:00
committed by George Panchuk
parent e7101dc5ba
commit 27633971df

View File

@@ -21,7 +21,7 @@ def upload_batch_grpc(
max_retries: int,
shard_key_selector: grpc.ShardKeySelector | None, # type: ignore[name-defined]
update_filter: grpc.Filter | None,
update_mode: grpc.UpdateMode | None = None,
update_mode: grpc.UpdateMode = None, # type: ignore # protobuf < 5.29 does not allow Union[enum, None]
wait: bool = False,
timeout: int | None = None,
) -> bool: