docs(code): add concise docstrings

This commit is contained in:
2026-07-14 11:05:07 +03:30
parent c54f6edc1e
commit 5f88e964f6
20 changed files with 299 additions and 26 deletions

View File

@@ -19,12 +19,16 @@ from gapido_auth.infrastructure.sms_provider import get_sms_template
@dataclass(slots=True)
class AppContainer:
"""Runtime dependencies that need explicit shutdown after the gRPC server stops."""
auth_service: AuthService
mongo_client: AsyncIOMotorClient[Any]
redis: Redis
async def build_auth_service(settings: Settings, rabbitmq_channel: AbstractChannel) -> AppContainer:
"""Create repositories, adapters, policies, and the AuthService use-case object."""
mongo_client: AsyncIOMotorClient[Any] = AsyncIOMotorClient(settings.mongo_uri)
db = mongo_client[settings.mongo_db_name]
users = MongoUserRepository(db)