fix: add specific exceptions
This commit is contained in:
parent
f589397f25
commit
6ee7ca1890
@ -283,7 +283,7 @@ class ApiBasedToolSchemaParser:
|
|||||||
api = openai_plugin["api"]
|
api = openai_plugin["api"]
|
||||||
api_url = api["url"]
|
api_url = api["url"]
|
||||||
api_type = api["type"]
|
api_type = api["type"]
|
||||||
except:
|
except JSONDecodeError:
|
||||||
raise ToolProviderNotFoundError("Invalid openai plugin json.")
|
raise ToolProviderNotFoundError("Invalid openai plugin json.")
|
||||||
|
|
||||||
if api_type != "openapi":
|
if api_type != "openapi":
|
||||||
|
Loading…
Reference in New Issue
Block a user