Skip to content

Commit

Permalink
Merge pull request #15 from zhayujie/master
Browse files Browse the repository at this point in the history
fix: toolhub request_timeout should be str
  • Loading branch information
congxuma authored Apr 17, 2023
2 parents 672ac22 + 2f732e5 commit fa8762b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion plugins/plugin_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ def activate_plugins(self): # 生成新开启的插件实例
try:
instance = plugincls()
except Exception as e:
logger.warn("Failed to init %s, diabled. %s" % (name, e))
logger.error("Failed to init %s, diabled. %s" % (name, e))
self.disable_plugin(name)
failed_plugins.append(name)
continue
Expand Down
2 changes: 1 addition & 1 deletion plugins/tool/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ def _build_tool_kwargs(self, kwargs: dict):
return {
"openai_api_key": conf().get("open_ai_api_key", ""),
"proxy": conf().get("proxy", ""),
"request_timeout": conf().get("request_timeout", 60),
"request_timeout": str(conf().get("request_timeout", 60)),
# note: 目前tool暂未对其他模型测试,但这里仍对配置来源做了优先级区分,一般插件配置可覆盖全局配置
"model_name": tool_model_name
if tool_model_name
Expand Down

0 comments on commit fa8762b

Please sign in to comment.