mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-03-01 21:06:53 +08:00
Use typing_extensions.Self instead of _typeshed.Self (#9702)
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
from _typeshed import Self
|
||||
from collections.abc import Callable, Iterable, Mapping, Sequence
|
||||
from types import TracebackType
|
||||
from typing import Any, TypeVar, overload
|
||||
from typing_extensions import Literal, TypeAlias
|
||||
from typing_extensions import Literal, Self, TypeAlias
|
||||
|
||||
import psycopg2
|
||||
import psycopg2.extensions
|
||||
@@ -105,11 +104,11 @@ class cursor:
|
||||
def scroll(self, value, mode=...): ...
|
||||
def setinputsizes(self, sizes): ...
|
||||
def setoutputsize(self, size, column=...): ...
|
||||
def __enter__(self: Self) -> Self: ...
|
||||
def __enter__(self) -> Self: ...
|
||||
def __exit__(
|
||||
self, type: type[BaseException] | None, value: BaseException | None, traceback: TracebackType | None
|
||||
) -> None: ...
|
||||
def __iter__(self: Self) -> Self: ...
|
||||
def __iter__(self) -> Self: ...
|
||||
def __next__(self) -> tuple[Any, ...]: ...
|
||||
|
||||
_Cursor: TypeAlias = cursor
|
||||
@@ -462,7 +461,7 @@ class connection:
|
||||
def tpc_recover(self) -> list[Xid]: ...
|
||||
def tpc_rollback(self, __xid: str | bytes | Xid = ...) -> None: ...
|
||||
def xid(self, format_id, gtrid, bqual) -> Xid: ...
|
||||
def __enter__(self: Self) -> Self: ...
|
||||
def __enter__(self) -> Self: ...
|
||||
def __exit__(self, __type: object, __name: object, __tb: object) -> None: ...
|
||||
|
||||
class lobject:
|
||||
|
||||
Reference in New Issue
Block a user