fix: prevent null default_port for terminal tools
This commit is contained in:
@@ -185,6 +185,7 @@ services:
|
||||
"category": "ai-assistant",
|
||||
"interface_type": "terminal",
|
||||
"requires_port": False,
|
||||
"default_port": 0,
|
||||
"compose_template": """version: "3.8"
|
||||
services:
|
||||
opencode:
|
||||
@@ -247,7 +248,8 @@ volumes:
|
||||
existing.definition_type = "compose"
|
||||
existing.compose_template = tool_data["compose_template"]
|
||||
existing.required_variables = tool_data["required_variables"]
|
||||
existing.default_port = tool_data.get("default_port")
|
||||
if "default_port" in tool_data:
|
||||
existing.default_port = tool_data["default_port"]
|
||||
logger.info("Updated built-in tool type: %s", tool_data["name"])
|
||||
|
||||
await session.commit()
|
||||
|
||||
Reference in New Issue
Block a user