mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-16 08:47:39 +08:00
psycopg2: correct return type (#7607)
Fixes the return type of `psycopg2.cursor.fetchone()` to match the psycopg2 code:1d3a89a0bb/psycopg/cursor_type.c (L647-L651)1d3a89a0bb/psycopg/cursor_type.c (L748-L786)It also matches the [psycopg2 documentation](https://www.psycopg.org/docs/cursor.html?highlight=copy_from#cursor.fetchone) as well as the [DB-API](https://peps.python.org/pep-0249/#fetchone)
This commit is contained in:
@@ -368,7 +368,7 @@ class cursor:
|
||||
def executemany(self, query: str | bytes | Composable, vars_list: Iterable[_Vars]) -> None: ...
|
||||
def fetchall(self) -> list[tuple[Any, ...]]: ...
|
||||
def fetchmany(self, size=...) -> list[tuple[Any, ...]]: ...
|
||||
def fetchone(self) -> tuple[Any, ...] | Any: ...
|
||||
def fetchone(self) -> tuple[Any, ...] | None: ...
|
||||
def mogrify(self, *args, **kwargs): ...
|
||||
def nextset(self): ...
|
||||
def scroll(self, value, mode=...): ...
|
||||
|
||||
Reference in New Issue
Block a user