Add some missing logging features (#5388)

This commit is contained in:
spaghEddieDoyle
2021-05-11 01:52:40 -07:00
committed by GitHub
parent dd73f117f0
commit 4c72f7f268
3 changed files with 229 additions and 73 deletions

View File

@@ -3,16 +3,39 @@ from _typeshed import AnyPath, StrPath
from collections.abc import Callable
from configparser import RawConfigParser
from threading import Thread
from typing import IO, Any, Optional, Union
from typing import IO, Any, Optional, Pattern, Union
if sys.version_info >= (3, 8):
from typing import Literal
else:
from typing_extensions import Literal
if sys.version_info >= (3, 7):
_Path = AnyPath
else:
_Path = StrPath
DEFAULT_LOGGING_CONFIG_PORT: int
RESET_ERROR: int # undocumented
IDENTIFIER: Pattern[str] # undocumented
def dictConfig(config: dict[str, Any]) -> None: ...
def fileConfig(
fname: Union[_Path, IO[str], RawConfigParser], defaults: Optional[dict[str, str]] = ..., disable_existing_loggers: bool = ...
) -> None: ...
if sys.version_info >= (3, 10):
def fileConfig(
fname: Union[_Path, IO[str], RawConfigParser],
defaults: Optional[dict[str, str]] = ...,
disable_existing_loggers: bool = ...,
encoding: Optional[str] = ...,
) -> None: ...
else:
def fileConfig(
fname: Union[_Path, IO[str], RawConfigParser],
defaults: Optional[dict[str, str]] = ...,
disable_existing_loggers: bool = ...,
) -> None: ...
def valid_ident(s: str) -> Literal[True]: ... # undocumented
def listen(port: int = ..., verify: Optional[Callable[[bytes], Optional[bytes]]] = ...) -> Thread: ...
def stopListening() -> None: ...