HyukjinKwon commented on a change in pull request #34363: URL: https://github.com/apache/spark/pull/34363#discussion_r734240526
########## File path: python/pyspark/accumulators.py ########## @@ -20,20 +20,32 @@ import struct import socketserver as SocketServer import threading +from typing import TypeVar, Generic, Tuple, Callable, Type, Dict, Union, TYPE_CHECKING + from pyspark.serializers import read_int, PickleSerializer +if TYPE_CHECKING: + from pyspark._typing import SupportsIAdd + import socketserver.BaseRequestHandler # type: ignore Review comment: why do we need ignore here? ########## File path: python/pyspark/accumulators.py ########## @@ -264,7 +281,12 @@ def authenticate_and_accum_updates(): class AccumulatorServer(SocketServer.TCPServer): - def __init__(self, server_address, RequestHandlerClass, auth_token): + def __init__( + self, + server_address: Tuple[str, int], + RequestHandlerClass: Type["socketserver.BaseRequestHandler"], Review comment: what's diff between `Type["socketserver.BaseRequestHandler"]` and `"socketserver.BaseRequestHandler"`? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org