mirror of
https://github.com/fastapi-users/fastapi-users.git
synced 2025-08-16 11:53:40 +08:00

* Move users router in sub-module * Factorize UserRouter into EventHandlersRouter * Implement OAuth registration/login router * Apply isort/black * Remove temporary pytest marker * Fix httpx-oauth version in lock file * Ensure ON_AFTER_REGISTER event is triggered on OAuth registration * Add API on FastAPIUsers to generate an OAuth router * Improve test coverage of FastAPIUsers * Small fixes * Write the OAuth documentation * Fix SQL unit-tests by avoiding collisions in SQLite db files
25 lines
641 B
Python
25 lines
641 B
Python
from fastapi_users.db.base import BaseUserDatabase # noqa: F401
|
|
|
|
try:
|
|
from fastapi_users.db.mongodb import MongoDBUserDatabase # noqa: F401
|
|
except ImportError: # pragma: no cover
|
|
pass
|
|
|
|
try:
|
|
from fastapi_users.db.sqlalchemy import ( # noqa: F401
|
|
SQLAlchemyBaseOAuthAccountTable,
|
|
SQLAlchemyBaseUserTable,
|
|
SQLAlchemyUserDatabase,
|
|
)
|
|
except ImportError: # pragma: no cover
|
|
pass
|
|
|
|
try:
|
|
from fastapi_users.db.tortoise import ( # noqa: F401
|
|
TortoiseBaseOAuthAccountModel,
|
|
TortoiseBaseUserModel,
|
|
TortoiseUserDatabase,
|
|
)
|
|
except ImportError: # pragma: no cover
|
|
pass
|