Skip to content

Commit 6341f44

Browse files
committed
format
1 parent b2f0dbc commit 6341f44

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

unstructured_platform_plugins/etl_uvicorn/api_generator.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -136,11 +136,8 @@ async def _stream_response():
136136

137137
return StreamingResponse(_stream_response(), media_type="application/x-ndjson")
138138
else:
139-
return InvokeResponse(
140-
usage=usage,
141-
status_code=status.HTTP_200_OK,
142-
output=await invoke_func(func, request_dict),
143-
)
139+
output = await invoke_func(func=func, kwargs=request_dict)
140+
return InvokeResponse(usage=usage, status_code=status.HTTP_200_OK, output=output)
144141
except Exception as invoke_error:
145142
logger.error(f"failed to invoke plugin: {invoke_error}", exc_info=True)
146143
return InvokeResponse(

0 commit comments

Comments
 (0)