File tree Expand file tree Collapse file tree
backend/src/acidwatch_api Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11from __future__ import annotations
22
33from collections import defaultdict
4- from typing import Annotated , Any
4+ from typing import Annotated
55from uuid import UUID , uuid4
66from acidwatch_api .models .datamodel import (
77 ModelInfo ,
1212from azure .monitor .opentelemetry import configure_azure_monitor
1313from fastapi import Depends , HTTPException , Security
1414from fastapi .middleware .cors import CORSMiddleware
15- from starlette .status import HTTP_404_NOT_FOUND
1615from traceback import format_exception , print_exception
1716from pydantic import ValidationError
1817
@@ -152,15 +151,6 @@ async def run_model(
152151 return result
153152
154153
155- @fastapi_app .get ("/results/{result_id}" )
156- def get_result (result_id : UUID ) -> Any :
157- if (result := RESULTS .get (result_id )) is None :
158- raise HTTPException (HTTP_404_NOT_FOUND )
159- if isinstance (result , BaseException ):
160- return {"error" : format_exception (result )}
161- return result
162-
163-
164154fastapi_app .include_router (project_endpoints .router )
165155
166156app = CORSMiddleware (
You can’t perform that action at this time.
0 commit comments