Update stubs

This commit is contained in:
Trinh Anh Ngoc
2021-11-02 09:25:19 +07:00
parent 7055c0f088
commit 89e356bfcb
2 changed files with 9 additions and 5 deletions

View File

@@ -1,6 +1,8 @@
from collections.abc import Mapping from collections.abc import Mapping
from typing import Any from typing import Any
from odoo.sql_db import Cursor
_logger: Any _logger: Any
_schema: Any _schema: Any
@@ -83,7 +85,7 @@ class Registry(Mapping):
def in_test_mode(self): ... def in_test_mode(self): ...
def enter_test_mode(self, cr) -> None: ... def enter_test_mode(self, cr) -> None: ...
def leave_test_mode(self) -> None: ... def leave_test_mode(self) -> None: ...
def cursor(self): ... def cursor(self) -> Cursor: ...
class DummyRLock: class DummyRLock:
def acquire(self) -> None: ... def acquire(self) -> None: ...

View File

@@ -1,6 +1,8 @@
import psycopg2.extensions import psycopg2.extensions
from typing import Any from typing import Any
from odoo.tools import Callbacks
_logger: Any _logger: Any
def unbuffer(symb, cr): ... def unbuffer(symb, cr): ...
@@ -16,10 +18,10 @@ sql_counter: int
def check(f, self, *args, **kwargs): ... def check(f, self, *args, **kwargs): ...
class BaseCursor: class BaseCursor:
precommit: Any precommit: Callbacks
postcommit: Any postcommit: Callbacks
prerollback: Any prerollback: Callbacks
postrollback: Any postrollback: Callbacks
transaction: Any transaction: Any
def __init__(self) -> None: ... def __init__(self) -> None: ...
def flush(self) -> None: ... def flush(self) -> None: ...