MCPcopy Create free account

hub / github.com/tortoise/tortoise-orm / functions

Functions3,850 in github.com/tortoise/tortoise-orm

↓ 2 callersMethoddb_for_write
(self, model: type[Model])
tortoise/router.py:44
↓ 2 callersMethoddescribe
(self, serializable: bool)
tortoise/fields/relational.py:294
↓ 2 callersFunctiondo_clear
()
examples/comprehensive_migrations_project/migrations/0011_populate_computed_fields.py:32
↓ 2 callersFunctiondo_populate
()
examples/comprehensive_migrations_project/migrations/0011_populate_computed_fields.py:20
↓ 2 callersMethoddrop_schema
Drop a database schema. Override in dialect-specific editors.
tortoise/migrations/schema_editor/base.py:465
↓ 2 callersMethodexecute_many
(self, query: str, values: list)
tortoise/backends/odbc/client.py:125
↓ 2 callersMethodexecute_query
( self, query: str, values: list | None = None, row_factory=psycopg.rows.dict_
tortoise/backends/psycopg/client.py:141
↓ 2 callersMethodexecute_query_dict_with_affected
Executes a RAW SQL query statement, and returns the resultset as a list of dicts along with the rows affected if available.
tortoise/backends/base/client.py:245
↓ 2 callersMethodexecute_script
(self, query: str)
tortoise/backends/base_postgres/client.py:155
↓ 2 callersMethodexecute_script
(self, query: str)
tests/utils/fake_client.py:44
↓ 2 callersMethodexecute_select
( self, sql: str, values: list | None = None, custom_fields: list | None = Non
tortoise/backends/base/executor.py:103
↓ 2 callersMethodexecute_update
( self, instance: type[Model] | Model, update_fields: Iterable[str] | None )
tortoise/backends/base/executor.py:426
↓ 2 callersMethodfinalise_model
Finalise the model after it had been fully loaded.
tortoise/models.py:311
↓ 2 callersFunctionformat_annotation
(annotation, fully_qualified=False)
docs/sphinx_autodoc_typehints.py:22
↓ 2 callersMethodfrom_dict
(cls, env)
tortoise/migrations/schema_generator/state.py:18
↓ 2 callersMethodfrom_queryset_single
Returns a serializable pydantic model instance for a single model from the provided queryset. This will prefetch all the rel
tortoise/contrib/pydantic/base.py:101
↓ 2 callersMethodfull_hierarchy__async_for
Demonstrates ``async for` to fetch relations An async iterator will fetch the relationship on-demand.
examples/relations_recursive.py:32
↓ 2 callersFunctiongenerate_schema_for_client
Generates and applies the SQL schema directly to the given client. :param client: The DB client to generate Schema SQL for :param safe:
tortoise/utils.py:35
↓ 2 callersFunctionget_annotations
Get all annotations including base classes. Builds a namespace from the Tortoise apps registry so that forward references (string annota
tortoise/contrib/pydantic/utils.py:10
↓ 2 callersMethodget_filter
(self, key: str)
tortoise/models.py:308
↓ 2 callersFunctionget_json_filter_operator
Extracts the key parts, filter value and operator from a JSON filter dictionary.
tortoise/query_utils.py:277
↓ 2 callersMethodget_sql
(self, ctx)
tortoise/contrib/postgres/search.py:67
↓ 2 callersMethodget_sql
(self, _context=None, dialect: str | None = None)
tortoise/fields/db_defaults.py:30
↓ 2 callersFunctionget_timezone
Get timezone from env set in Tortoise config.
tortoise/timezone.py:52
↓ 2 callersFunctionget_together
(meta: Model.Meta, together: str)
tortoise/models.py:68
↓ 2 callersFunctioninit_apps
(*models: type[Model])
tests/migrations/test_schema_editor_backend_parity.py:38
↓ 2 callersMethodinit_routers
(self, routers: list[Callable])
tortoise/router.py:17
↓ 2 callersFunctionis_naive
Determine if a given datetime.datetime or datetime.time is naive. The concept is defined in Python's docs: https://docs.python.org/libra
tortoise/timezone.py:133
↓ 2 callersFunctionload_schema_generator
(module_path: Path, class_name: str)
tests/migrations/test_schema_editor_backend_parity.py:28
↓ 2 callersFunctionmain
()
tortoise/cli/cli.py:869
↓ 2 callersFunctionmake_text_field
(source_field: str | None)
tests/migrations/test_state_diff_operations.py:58
↓ 2 callersFunctionmigrations_module_path
(module_name: str)
tortoise/migrations/writer.py:57
↓ 2 callersFunctionnormalize_statements
(sql: str)
tests/migrations/test_schema_editor_backend_parity.py:106
↓ 2 callersMethodraw
Executes a RAW SQL and returns the result .. code-block:: python3 result = await User.raw("select * from users where na
tortoise/models.py:1577
↓ 2 callersMethodremove_constraint
(self, model, constraint)
tortoise/migrations/schema_editor/sqlite.py:182
↓ 2 callersMethodremove_field
(self, model: type[Model], field)
tortoise/migrations/schema_editor/mssql.py:283
↓ 2 callersMethodrename_table
(self, model: type[Model], old_name: str, new_name: str)
tortoise/migrations/schema_editor/mssql.py:63
↓ 2 callersMethodrender
(self)
tortoise/migrations/writer.py:87
↓ 2 callersFunctionresolve_field_json_path
Resolves a JSON path from a list of key parts, e.g. converting (field, ['a', 'b', 'c']) to field->'a'->'b'->>'c'. Returns a pypika Term.
tortoise/query_utils.py:293
↓ 2 callersFunctionresolve_nested_field
Resolves a nested field string like events__participants__name and returns the pypika term, required joins and the Field that can be used for
tortoise/query_utils.py:106
↓ 2 callersMethodresolve_to_python_value
(self, model: type[MODEL], field: str)
tortoise/queryset.py:1585
↓ 2 callersMethodrollback
(self)
tortoise/backends/sqlite/client.py:244
↓ 2 callersMethodrollback
(self)
tortoise/backends/asyncpg/client.py:212
↓ 2 callersMethodroot_nodes
(self, app_label: str | None = None)
tortoise/migrations/graph.py:113
↓ 2 callersFunctionrun
()
examples/pydantic/basic.py:61
↓ 2 callersFunctionschema_editor_sql
(editor: BaseSchemaEditor, model: type[Model])
tests/migrations/test_schema_editor_backend_parity.py:116
↓ 2 callersFunctionschema_generator_sql
( generator_cls: type[BaseSchemaGenerator], client: BaseDBAsyncClient, model: type[Model], mod
tests/migrations/test_schema_editor_backend_parity.py:122
↓ 2 callersFunctionskip_if_not_postgres
Skip test if not running against PostgreSQL.
tests/contrib/postgres/test_search.py:19
↓ 2 callersMethodstate_forward
(self, app_label: str, state: State)
tortoise/migrations/operations.py:407
↓ 2 callersMethodstate_forward
(self, app_label: str, state: State)
tortoise/migrations/operations.py:507
↓ 2 callersMethodtimezone
Get the timezone configured for this context. Returns: The timezone string (e.g., "UTC", "America/New_York").
tortoise/context.py:220
↓ 2 callersFunctiontortoise_init
()
tortoise/contrib/sanic/__init__.py:84
↓ 2 callersMethoduser_list
(self, async_client: AsyncClient)
examples/fastapi/_tests.py:80
↓ 2 callersMethodvalidate_consistency
(self)
tortoise/migrations/graph.py:108
↓ 2 callersMethodvalidate_model_name
(cls, model_name: str | type[Model])
tortoise/fields/relational.py:301
↓ 2 callersMethodvalues
Make QuerySet return dicts instead of objects. If called after `.get()`, `.get_or_none()` or `.first()`, returns a dict instead of a
tortoise/queryset.py:689
↓ 2 callersMethodwrite
(self)
tortoise/migrations/writer.py:280
↓ 1 callersMethod__aenter__
(self)
tortoise/contrib/fastapi/__init__.py:194
↓ 1 callersMethod__aenter__
(self)
tortoise/backends/base/client.py:300
↓ 1 callersMethod__await__
(self)
tortoise/fields/relational.py:23
↓ 1 callersMethod__exit__
Exit the context manager and restore the previous context.
tortoise/context.py:497
↓ 1 callersMethod__init__
( self, *expressions: Term | Expression, fields: tuple[str, ...] | list[str] | None =
tortoise/indexes.py:28
↓ 1 callersMethod__init__
(self, element_type: str = "int", **kwargs: Any)
tortoise/contrib/postgres/fields.py:94
↓ 1 callersMethod__init__
(self, *args: Any)
tortoise/contrib/test/condition.py:20
↓ 1 callersMethod__init__
(self, column_name: Term, query_list: list[int | str | Term])
tortoise/contrib/mysql/json_functions.py:21
↓ 1 callersMethod__init__
(self, config: str | None, config_file: str | None)
tortoise/cli/cli.py:362
↓ 1 callersMethod__init__
( self, *, user: str, password: str, host: str, port: Supports
tortoise/backends/mssql/client.py:35
↓ 1 callersMethod__init__
(self, key: MigrationKey)
tortoise/migrations/graph.py:22
↓ 1 callersMethod__init__
(self)
tortoise/fields/db_defaults.py:56
↓ 1 callersMethod__init__
( self, dialect: str, *, inline_comment: bool = True, charset: str | None = None )
tests/utils/fake_client.py:12
↓ 1 callersMethod__init__
(self, enum_type: type[Enum], **kwargs)
tests/fields/subclass_fields.py:18
↓ 1 callersFunction_add_downgrade_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:757
↓ 1 callersMethod_add_external_dependencies
(self, key: MigrationKey, migration: Migration)
tortoise/migrations/loader.py:111
↓ 1 callersFunction_add_global_options
(parser: argparse.ArgumentParser)
tortoise/cli/cli.py:691
↓ 1 callersFunction_add_heads_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:778
↓ 1 callersFunction_add_history_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:770
↓ 1 callersFunction_add_init_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:704
↓ 1 callersMethod_add_internal_dependencies
(self, key: MigrationKey, migration: Migration)
tortoise/migrations/loader.py:105
↓ 1 callersFunction_add_makemigrations_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:719
↓ 1 callersFunction_add_migrate_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:731
↓ 1 callersMethod_add_returning_to_insert
Hook for backends to add RETURNING clause. Base implementation does nothing (backends without RETURNING support). Override in Postgre
tortoise/backends/base/executor.py:264
↓ 1 callersFunction_add_shell_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:712
↓ 1 callersFunction_add_sqlmigrate_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:784
↓ 1 callersFunction_add_upgrade_parser
(subparsers: argparse._SubParsersAction)
tortoise/cli/cli.py:744
↓ 1 callersMethod_alter_column_comment
Alter column comment. Override in backends that support column comments.
tortoise/migrations/schema_editor/base.py:85
↓ 1 callersMethod_alter_field
(self, model: type[Model], old_field: Field, new_field: Field)
tortoise/migrations/schema_editor/mssql.py:125
↓ 1 callersMethod_alter_field
(self, model: type[Model], old_field: Field, new_field: Field)
tortoise/migrations/schema_editor/base.py:616
↓ 1 callersMethod_alter_generated_field
( self, model: type[Model], old_field: Field, new_field: Field )
tortoise/migrations/schema_editor/base.py:591
↓ 1 callersMethod_alter_m2m_field
( self, model: type[Model], old_field: ManyToManyFieldInstance, new_field: Man
tortoise/migrations/schema_editor/base.py:557
↓ 1 callersMethod_apply_on_conflict
Apply ON CONFLICT ... DO UPDATE to both query variants.
tortoise/queryset.py:2092
↓ 1 callersMethod_as_tsquery
(self)
tortoise/contrib/postgres/search.py:471
↓ 1 callersFunction_base_signature
(bases: Iterable[type])
tortoise/migrations/schema_generator/state_diff.py:89
↓ 1 callersFunction_bench
()
tests/benchmarks/test_state_building.py:54
↓ 1 callersFunction_bench
()
tests/benchmarks/test_relations.py:11
↓ 1 callersMethod_build_default_values_sql
Build INSERT SQL for when all columns are omitted.
tortoise/queryset.py:2075
↓ 1 callersMethod_build_initial_querysets
(self)
tortoise/apps.py:115
↓ 1 callersFunction_build_migrations
(num_models: int, batch_size: int = 20)
tests/benchmarks/test_state_building.py:33
↓ 1 callersFunction_build_parser
()
tortoise/cli/cli.py:796
↓ 1 callersFunction_capture_output
(cmd: str)
tests/test_version.py:46
↓ 1 callersMethod_check
Calls various checks to validate the model. :raises ConfigurationError: If the model has not been configured correctly.
tortoise/models.py:1642
← previousnext →501–600 of 3,850, ranked by callers