mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 13:34:58 +08:00
Make more miscellaneous fields read-only, annotate _json.make_encoder (#7439)
This commit is contained in:
@@ -2,7 +2,7 @@ import sys
|
||||
from _typeshed import Self
|
||||
from concurrent.futures._base import Error, Future as _ConcurrentFuture
|
||||
from typing import Any, Awaitable, Callable, Generator, Iterable, TypeVar
|
||||
from typing_extensions import TypeGuard
|
||||
from typing_extensions import Literal, TypeGuard
|
||||
|
||||
from .events import AbstractEventLoop
|
||||
|
||||
@@ -42,9 +42,13 @@ if sys.version_info < (3, 7):
|
||||
|
||||
class Future(Awaitable[_T], Iterable[_T]):
|
||||
_state: str
|
||||
_exception: BaseException
|
||||
@property
|
||||
def _exception(self) -> BaseException: ...
|
||||
_blocking: bool
|
||||
_log_traceback: bool
|
||||
@property
|
||||
def _log_traceback(self) -> bool: ...
|
||||
@_log_traceback.setter
|
||||
def _log_traceback(self, val: Literal[False]) -> None: ...
|
||||
_asyncio_future_blocking: bool # is a part of duck-typing contract for `Future`
|
||||
def __init__(self, *, loop: AbstractEventLoop | None = ...) -> None: ...
|
||||
def __del__(self) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user