mirror of
https://github.com/odoo-ide/odoo-stubs.git
synced 2025-05-08 16:52:26 +03:00
Update stubs
This commit is contained in:
@@ -45,7 +45,7 @@ def _call_kw_model_create(method: Callable[..., _ModelT], self: _ModelT, args, k
|
||||
def _call_kw_multi(method: Callable[..., _ModelT], self: _ModelT, args, kwargs): ...
|
||||
def call_kw(model: BaseModel, name: str, args, kwargs): ...
|
||||
|
||||
class Environment(Mapping):
|
||||
class Environment(Mapping[str, BaseModel]):
|
||||
cr: Cursor = ...
|
||||
uid: int = ...
|
||||
context: dict[str, Any] = ...
|
||||
|
||||
@@ -318,7 +318,7 @@ class BaseModel(metaclass=MetaModel):
|
||||
def _onchange_eval(self, field_name: str, onchange: str, result: dict) -> None: ...
|
||||
def onchange(self, values: dict[str, Any], field_name: str | list[str] | bool, field_onchange: dict[str, str]) -> dict: ...
|
||||
def _get_placeholder_filename(self, field: str) -> str | bool: ...
|
||||
def _populate_factories(self) -> list[tuple[str, Iterator]]: ...
|
||||
def _populate_factories(self) -> list[tuple[str, Callable[..., Iterator]]]: ...
|
||||
@property
|
||||
def _populate_sizes(self) -> dict[str, int]: ...
|
||||
@property
|
||||
|
||||
@@ -12,7 +12,7 @@ from ..tests.runner import OdooTestResult
|
||||
from ..tools import Collector
|
||||
from ..tools.lru import LRU
|
||||
|
||||
class Registry(Mapping):
|
||||
class Registry(Mapping[str, type[BaseModel]]):
|
||||
_lock: RLock
|
||||
_saved_lock: RLock | None
|
||||
registries: ClassVar[LRU]
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
from typing import Any
|
||||
from logging import Logger
|
||||
from typing import Any, Literal
|
||||
|
||||
_logger: Any
|
||||
RPC_VERSION_1: Any
|
||||
RPC_VERSION_1: dict[str, Any]
|
||||
|
||||
def exp_login(db, login, password): ...
|
||||
def exp_authenticate(db, login, password, user_agent_env): ...
|
||||
def exp_version(): ...
|
||||
def exp_about(extended: bool = ...): ...
|
||||
def exp_set_loglevel(loglevel, logger: Any | None = ...): ...
|
||||
def dispatch(method, params): ...
|
||||
def exp_login(db: str, login: str, password: str) -> int: ...
|
||||
def exp_authenticate(db: str, login: str, password: str, user_agent_env: dict | None) -> int: ...
|
||||
def exp_version() -> dict[str, Any]: ...
|
||||
def exp_about(extended: bool = ...) -> str | tuple[str, str]: ...
|
||||
def exp_set_loglevel(loglevel, logger: Logger | None = ...) -> Literal[True]: ...
|
||||
def dispatch(method: str, params): ...
|
||||
|
||||
@@ -1,31 +1,35 @@
|
||||
from functools import wraps as wraps
|
||||
from typing import Any
|
||||
from typing import Any, Callable, IO, Iterable, Literal, TypeVar
|
||||
|
||||
_logger: Any
|
||||
from ..sql_db import Cursor
|
||||
|
||||
_CallableT = TypeVar('_CallableT', bound=Callable)
|
||||
|
||||
class DatabaseExists(Warning): ...
|
||||
|
||||
def check_db_management_enabled(method): ...
|
||||
def check_super(passwd): ...
|
||||
def _initialize_db(id, db_name, demo, lang, user_password, login: str = ..., country_code: Any | None = ..., phone: Any | None = ...) -> None: ...
|
||||
def _create_empty_database(name) -> None: ...
|
||||
def exp_create_database(db_name, demo, lang, user_password: str = ..., login: str = ..., country_code: Any | None = ..., phone: Any | None = ...): ...
|
||||
def exp_duplicate_database(db_original_name, db_name): ...
|
||||
def _drop_conn(cr, db_name) -> None: ...
|
||||
def exp_drop(db_name): ...
|
||||
def exp_dump(db_name, format): ...
|
||||
def dump_db_manifest(cr): ...
|
||||
def dump_db(db_name, stream, backup_format: str = ...): ...
|
||||
def exp_restore(db_name, data, copy: bool = ...): ...
|
||||
def restore_db(db, dump_file, copy: bool = ...) -> None: ...
|
||||
def exp_rename(old_name, new_name): ...
|
||||
def exp_change_admin_password(new_password): ...
|
||||
def exp_migrate_databases(databases): ...
|
||||
def exp_db_exist(db_name): ...
|
||||
def list_dbs(force: bool = ...): ...
|
||||
def list_db_incompatible(databases): ...
|
||||
def exp_list(document: bool = ...): ...
|
||||
def exp_list_lang(): ...
|
||||
def exp_list_countries(): ...
|
||||
def exp_server_version(): ...
|
||||
def dispatch(method, params): ...
|
||||
def check_db_management_enabled(method: _CallableT) -> _CallableT: ...
|
||||
def check_super(passwd: str) -> Literal[True]: ...
|
||||
def _initialize_db(id, db_name: str, demo: bool, lang: str, user_password: str, login: str = ...,
|
||||
country_code: str | None = ..., phone: str | None = ...) -> None: ...
|
||||
def _create_empty_database(name: str) -> None: ...
|
||||
def exp_create_database(db_name: str, demo: bool, lang: str, user_password: str = ..., login: str = ...,
|
||||
country_code: str | None = ..., phone: str | None = ...) -> Literal[True]: ...
|
||||
def exp_duplicate_database(db_original_name: str, db_name: str) -> Literal[True]: ...
|
||||
def _drop_conn(cr: Cursor, db_name: str) -> None: ...
|
||||
def exp_drop(db_name: str) -> bool: ...
|
||||
def exp_dump(db_name: str, format: str) -> str: ...
|
||||
def dump_db_manifest(cr: Cursor) -> dict[str, Any]: ...
|
||||
def dump_db(db_name: str, stream, backup_format: str = ...) -> IO | None: ...
|
||||
def exp_restore(db_name: str, data, copy: bool = ...) -> Literal[True]: ...
|
||||
def restore_db(db: str, dump_file: str, copy: bool = ...) -> None: ...
|
||||
def exp_rename(old_name: str, new_name: str) -> Literal[True]: ...
|
||||
def exp_change_admin_password(new_password: str) -> Literal[True]: ...
|
||||
def exp_migrate_databases(databases: Iterable[str]) -> Literal[True]: ...
|
||||
def exp_db_exist(db_name: str) -> bool: ...
|
||||
def list_dbs(force: bool = ...) -> list[str]: ...
|
||||
def list_db_incompatible(databases: Iterable[str]) -> list[str]: ...
|
||||
def exp_list(document: bool = ...) -> list[str]: ...
|
||||
def exp_list_lang() -> list[tuple[str, str]]: ...
|
||||
def exp_list_countries() -> list[tuple[str, str]]: ...
|
||||
def exp_server_version() -> str: ...
|
||||
def dispatch(method: str, params): ...
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
from typing import Any
|
||||
from typing import Any, Callable, TypeVar
|
||||
|
||||
_logger: Any
|
||||
PG_CONCURRENCY_ERRORS_TO_RETRY: Any
|
||||
from ..sql_db import Cursor
|
||||
|
||||
PG_CONCURRENCY_ERRORS_TO_RETRY: tuple[str, str, str]
|
||||
MAX_TRIES_ON_CONCURRENCY_FAILURE: int
|
||||
|
||||
def dispatch(method, params): ...
|
||||
def check(f): ...
|
||||
def execute_cr(cr, uid, obj, method, *args, **kw): ...
|
||||
def execute_kw(db, uid, obj, method, args, kw: Any | None = ...): ...
|
||||
def execute(db, uid, obj, method, *args, **kw): ...
|
||||
_CallableT = TypeVar('_CallableT', bound=Callable)
|
||||
|
||||
def dispatch(method: str, params): ...
|
||||
def check(f: _CallableT) -> _CallableT: ...
|
||||
def execute_cr(cr: Cursor, uid: int, obj: str, method: str, *args, **kw): ...
|
||||
def execute_kw(db: str, uid: int, obj: str, method: str, args, kw: dict | None = ...): ...
|
||||
def execute(db: str, uid: int, obj: str, method: str, *args, **kw): ...
|
||||
|
||||
Reference in New Issue
Block a user