mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-06 20:24:30 +08:00
Fix stubtest failures for socketserver on windows (#4103)
This commit is contained in:
@@ -63,23 +63,24 @@ if sys.platform != 'win32':
|
||||
RequestHandlerClass: Callable[..., BaseRequestHandler],
|
||||
bind_and_activate: bool = ...) -> None: ...
|
||||
|
||||
class ForkingMixIn:
|
||||
timeout: Optional[float] # undocumented
|
||||
active_children: Optional[List[int]] # undocumented
|
||||
max_children: int # undocumented
|
||||
if sys.version_info >= (3, 7):
|
||||
block_on_close: bool
|
||||
if sys.version_info >= (3, 6):
|
||||
def collect_children(self, *, blocking: bool = ...) -> None: ... # undocumented
|
||||
else:
|
||||
def collect_children(self) -> None: ... # undocumented
|
||||
def handle_timeout(self) -> None: ... # undocumented
|
||||
if sys.version_info >= (3, 3):
|
||||
def service_actions(self) -> None: ... # undocumented
|
||||
def process_request(self, request: bytes,
|
||||
client_address: Tuple[str, int]) -> None: ...
|
||||
if sys.version_info >= (3, 6):
|
||||
def server_close(self) -> None: ...
|
||||
if sys.platform != "win32":
|
||||
class ForkingMixIn:
|
||||
timeout: Optional[float] # undocumented
|
||||
active_children: Optional[List[int]] # undocumented
|
||||
max_children: int # undocumented
|
||||
if sys.version_info >= (3, 7):
|
||||
block_on_close: bool
|
||||
if sys.version_info >= (3, 6):
|
||||
def collect_children(self, *, blocking: bool = ...) -> None: ... # undocumented
|
||||
else:
|
||||
def collect_children(self) -> None: ... # undocumented
|
||||
def handle_timeout(self) -> None: ... # undocumented
|
||||
if sys.version_info >= (3, 3):
|
||||
def service_actions(self) -> None: ... # undocumented
|
||||
def process_request(self, request: bytes,
|
||||
client_address: Tuple[str, int]) -> None: ...
|
||||
if sys.version_info >= (3, 6):
|
||||
def server_close(self) -> None: ...
|
||||
|
||||
class ThreadingMixIn:
|
||||
daemon_threads: bool
|
||||
@@ -92,8 +93,9 @@ class ThreadingMixIn:
|
||||
if sys.version_info >= (3, 6):
|
||||
def server_close(self) -> None: ...
|
||||
|
||||
class ForkingTCPServer(ForkingMixIn, TCPServer): ...
|
||||
class ForkingUDPServer(ForkingMixIn, UDPServer): ...
|
||||
if sys.platform != "win32":
|
||||
class ForkingTCPServer(ForkingMixIn, TCPServer): ...
|
||||
class ForkingUDPServer(ForkingMixIn, UDPServer): ...
|
||||
class ThreadingTCPServer(ThreadingMixIn, TCPServer): ...
|
||||
class ThreadingUDPServer(ThreadingMixIn, UDPServer): ...
|
||||
if sys.platform != 'win32':
|
||||
|
||||
@@ -63,23 +63,24 @@ if sys.platform != 'win32':
|
||||
RequestHandlerClass: Callable[..., BaseRequestHandler],
|
||||
bind_and_activate: bool = ...) -> None: ...
|
||||
|
||||
class ForkingMixIn:
|
||||
timeout: Optional[float] # undocumented
|
||||
active_children: Optional[List[int]] # undocumented
|
||||
max_children: int # undocumented
|
||||
if sys.version_info >= (3, 7):
|
||||
block_on_close: bool
|
||||
if sys.version_info >= (3, 6):
|
||||
def collect_children(self, *, blocking: bool = ...) -> None: ... # undocumented
|
||||
else:
|
||||
def collect_children(self) -> None: ... # undocumented
|
||||
def handle_timeout(self) -> None: ... # undocumented
|
||||
if sys.version_info >= (3, 3):
|
||||
def service_actions(self) -> None: ... # undocumented
|
||||
def process_request(self, request: bytes,
|
||||
client_address: Tuple[str, int]) -> None: ...
|
||||
if sys.version_info >= (3, 6):
|
||||
def server_close(self) -> None: ...
|
||||
if sys.platform != "win32":
|
||||
class ForkingMixIn:
|
||||
timeout: Optional[float] # undocumented
|
||||
active_children: Optional[List[int]] # undocumented
|
||||
max_children: int # undocumented
|
||||
if sys.version_info >= (3, 7):
|
||||
block_on_close: bool
|
||||
if sys.version_info >= (3, 6):
|
||||
def collect_children(self, *, blocking: bool = ...) -> None: ... # undocumented
|
||||
else:
|
||||
def collect_children(self) -> None: ... # undocumented
|
||||
def handle_timeout(self) -> None: ... # undocumented
|
||||
if sys.version_info >= (3, 3):
|
||||
def service_actions(self) -> None: ... # undocumented
|
||||
def process_request(self, request: bytes,
|
||||
client_address: Tuple[str, int]) -> None: ...
|
||||
if sys.version_info >= (3, 6):
|
||||
def server_close(self) -> None: ...
|
||||
|
||||
class ThreadingMixIn:
|
||||
daemon_threads: bool
|
||||
@@ -92,8 +93,9 @@ class ThreadingMixIn:
|
||||
if sys.version_info >= (3, 6):
|
||||
def server_close(self) -> None: ...
|
||||
|
||||
class ForkingTCPServer(ForkingMixIn, TCPServer): ...
|
||||
class ForkingUDPServer(ForkingMixIn, UDPServer): ...
|
||||
if sys.platform != "win32":
|
||||
class ForkingTCPServer(ForkingMixIn, TCPServer): ...
|
||||
class ForkingUDPServer(ForkingMixIn, UDPServer): ...
|
||||
class ThreadingTCPServer(ThreadingMixIn, TCPServer): ...
|
||||
class ThreadingUDPServer(ThreadingMixIn, UDPServer): ...
|
||||
if sys.platform != 'win32':
|
||||
|
||||
12
third_party/2and3/werkzeug/serving.pyi
vendored
12
third_party/2and3/werkzeug/serving.pyi
vendored
@@ -2,12 +2,20 @@ import sys
|
||||
from typing import Any, Optional
|
||||
|
||||
if sys.version_info < (3,):
|
||||
from SocketServer import ThreadingMixIn, ForkingMixIn
|
||||
from SocketServer import ThreadingMixIn
|
||||
from BaseHTTPServer import HTTPServer, BaseHTTPRequestHandler
|
||||
else:
|
||||
from socketserver import ThreadingMixIn, ForkingMixIn
|
||||
from socketserver import ThreadingMixIn
|
||||
from http.server import HTTPServer, BaseHTTPRequestHandler
|
||||
|
||||
if sys.platform == "win32":
|
||||
class ForkingMixIn(object): ...
|
||||
else:
|
||||
if sys.version_info < (3,):
|
||||
from SocketServer import ForkingMixIn as ForkingMixIn
|
||||
else:
|
||||
from socketserver import ForkingMixIn as ForkingMixIn
|
||||
|
||||
class _SslDummy:
|
||||
def __getattr__(self, name): ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user