File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -49,12 +49,12 @@ def dict_value_types(arg: Dict) -> Dict:
4949 status .HTTP_200_OK : make_openapi_response (
5050 model_type = Dict , example = {"prediction" : "example" }
5151 ),
52- status .HTTP_500_INTERNAL_SERVER_ERROR : make_openapi_response (
53- mime_type = "text/plain" , example = EXAMPLE_TRACEBACK
54- )
55- if get_value ( "DEBUG" )
56- else make_openapi_response (
57- model_type = Message , example = Message ( "Internal Server Error" ). to_json ( )
52+ status .HTTP_500_INTERNAL_SERVER_ERROR : (
53+ make_openapi_response ( mime_type = "text/plain" , example = EXAMPLE_TRACEBACK )
54+ if get_value ( "DEBUG" )
55+ else make_openapi_response (
56+ model_type = Message , example = Message ( "Internal Server Error" ). to_json ()
57+ )
5858 ),
5959 status .HTTP_503_SERVICE_UNAVAILABLE : make_openapi_response (
6060 model_type = Message , example = Message ("Not Ready" ).to_json ()
Original file line number Diff line number Diff line change 11"""Settings file."""
2+
23import os
34from typing import Any , Dict
45
Original file line number Diff line number Diff line change 11"""This module implements the TrainedModelWrapper class."""
2+
23import os
34import os .path
45import importlib
You can’t perform that action at this time.
0 commit comments