// the find
tortoise/tortoise-orm
Familiar asyncio ORM for python, built with relations in mind
Tortoise ORM is an async-native Python ORM with a Django-like API, targeting FastAPI/Sanic/asyncio applications that need proper relation support without blocking I/O. It supports PostgreSQL, MySQL, SQLite, MSSQL, and Oracle with multiple async driver options per database. If you're building an async Python backend and miss Django's ORM ergonomics, this is the most mature option in that space.
Built-in migration framework with a CLI that does autodetection, reversible operations, RunPython/RunSQL, and multi-app projects — no need to bolt on Alembic separately. Multiple async driver choices per database (asyncpg vs psycopg for Postgres, aiomysql vs asyncmy for MySQL) means you're not locked into one library's quirks. Pydantic integration is first-class with generated serializers, not an afterthought. Benchmarks against SQLAlchemy async and others show competitive performance on PostgreSQL reads and writes.
The async context manager requirement for iteration is a footgun — you get silently cached results on the second loop, which will cause subtle bugs if you're not paying attention. Global Tortoise.init() state means testing and multi-tenancy are annoying; there's no clean per-request connection scoping like SQLAlchemy sessions give you. The migration autodetector has known gaps with complex schema changes (renaming models, cross-app FK changes), and the comprehensive_migrations_project example has 25 migrations just to cover edge cases — a sign the happy path isn't that wide. MS SQL and Oracle support is via asyncodbc which is slower and less battle-tested than the PostgreSQL drivers.