mirror of
https://github.com/flibusta-apps/users_settings_server.git
synced 2025-12-06 14:45:38 +01:00
Update deps and lint
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
from typing import Optional, Union
|
||||
|
||||
from fastapi import HTTPException, status
|
||||
|
||||
import ormsgpack
|
||||
from redis import asyncio as aioredis
|
||||
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
from datetime import datetime
|
||||
|
||||
from asyncpg.exceptions import UniqueViolationError
|
||||
from fastapi import APIRouter, Depends, HTTPException, Request, status
|
||||
|
||||
from asyncpg.exceptions import UniqueViolationError
|
||||
from fastapi_pagination import Page, Params
|
||||
from fastapi_pagination.ext.ormar import paginate
|
||||
from redis import asyncio as aioredis
|
||||
@@ -17,6 +18,7 @@ from app.serializers import (
|
||||
)
|
||||
from app.services.users_data_manager import UsersDataManager
|
||||
|
||||
|
||||
users_router = APIRouter(
|
||||
prefix="/users", tags=["users"], dependencies=[Depends(check_token)]
|
||||
)
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
from fastapi import FastAPI
|
||||
from fastapi.responses import ORJSONResponse
|
||||
|
||||
from fastapi_pagination import add_pagination
|
||||
from prometheus_fastapi_instrumentator import Instrumentator
|
||||
from redis import asyncio as aioredis
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
from fastapi.security import APIKeyHeader
|
||||
|
||||
|
||||
default_security = APIKeyHeader(name="Authorization")
|
||||
|
||||
@@ -5,6 +5,7 @@ from sqlalchemy import MetaData
|
||||
|
||||
from core.config import env_config
|
||||
|
||||
|
||||
DATABASE_URL = (
|
||||
f"postgresql://{env_config.POSTGRES_USER}:{quote(env_config.POSTGRES_PASSWORD)}@"
|
||||
f"{env_config.POSTGRES_HOST}:{env_config.POSTGRES_PORT}/{env_config.POSTGRES_DB}"
|
||||
|
||||
@@ -4,6 +4,7 @@ from sentry_sdk.integrations.asgi import SentryAsgiMiddleware
|
||||
from core.app import start_app
|
||||
from core.config import env_config
|
||||
|
||||
|
||||
sentry_sdk.init(dsn=env_config.SENTRY_SDN)
|
||||
|
||||
app = SentryAsgiMiddleware(start_app())
|
||||
|
||||
Reference in New Issue
Block a user