You've already forked RekomenciBackend
fix: fixed unimported statement
This commit is contained in:
+14
-2
@@ -2,7 +2,15 @@ from collections.abc import Callable
|
||||
from inspect import Parameter
|
||||
from typing import Final
|
||||
|
||||
from dishka import STRICT_VALIDATION, AsyncContainer, BaseScope, Provider, Scope, make_async_container, provide
|
||||
from dishka import (
|
||||
STRICT_VALIDATION,
|
||||
AsyncContainer,
|
||||
BaseScope,
|
||||
Provider,
|
||||
Scope,
|
||||
make_async_container,
|
||||
provide,
|
||||
)
|
||||
from dishka.integrations.base import wrap_injection
|
||||
from dishka.integrations.fastapi import FastapiProvider
|
||||
from httpx import AsyncClient
|
||||
@@ -14,6 +22,7 @@ from template_project.web_api.configuration import (
|
||||
Configuration,
|
||||
DatabaseConfiguration,
|
||||
ServerConfiguration,
|
||||
YandexOAuthConfiguration,
|
||||
)
|
||||
from template_project.web_api.ioc.connection import ConnectionProvider
|
||||
from template_project.web_api.ioc.cryptographer import CryptographerProvider
|
||||
@@ -21,6 +30,7 @@ from template_project.web_api.ioc.data_gateway import DataGatewayProvider
|
||||
from template_project.web_api.ioc.factory import FactoryProvider
|
||||
from template_project.web_api.ioc.idp import IdPProvider
|
||||
from template_project.web_api.ioc.interactor import InteractorProvider
|
||||
from template_project.web_api.ioc.oauth import OAuthClientProvider
|
||||
|
||||
|
||||
class DatabaseClearer:
|
||||
@@ -82,7 +92,9 @@ def make_ioc(configuration: Configuration) -> AsyncContainer:
|
||||
CONTAINER_PARAM: Final = "dishka_container"
|
||||
|
||||
|
||||
def inject[ReturnT, **FuncParams](func: Callable[FuncParams, ReturnT]) -> Callable[FuncParams, ReturnT]:
|
||||
def inject[ReturnT, **FuncParams](
|
||||
func: Callable[FuncParams, ReturnT],
|
||||
) -> Callable[FuncParams, ReturnT]:
|
||||
return wrap_injection(
|
||||
func=func,
|
||||
is_async=True,
|
||||
|
||||
Reference in New Issue
Block a user