Runs Code Formater

This commit is contained in:
2024-04-02 02:46:06 -03:00
parent c1fe79b4ac
commit 0b1b89de17
8 changed files with 31 additions and 26 deletions

View File

@@ -1,6 +1,6 @@
from storage_service.config.config_allowed_origins import get_allowed_origins
from storage_service.controller.storage_controller import s3_router
from storage_service.controller.health_checker_controller import health_router
from storage_service.controller.storage_controller import s3_router
from fastapi import FastAPI
from fastapi.middleware.cors import CORSMiddleware

View File

@@ -1,9 +1,9 @@
from fastapi_utils.cbv import cbv
from fastapi_utils.inferring_router import InferringRouter
health_router = InferringRouter()
@cbv(health_router)
class HealthCheckerController:
@health_router.get("/health", status_code=200)

View File

@@ -45,9 +45,7 @@ class StorageController:
@s3_router.delete("/file/", status_code=204)
def delete_file(self, username: str, file_postfix: str):
return self.storage_service.delete_file(
file_name_hash(username, file_postfix)
)
return self.storage_service.delete_file(file_name_hash(username, file_postfix))
@s3_router.post("/file/process", status_code=200)
def process_file(
@@ -56,5 +54,3 @@ class StorageController:
file_postfix: Annotated[str, Body(embed=True)],
):
self.queue.enqueue(storage_file_worker, username, file_postfix)