mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-10-22 19:02:23 +03:00
Rename device_command_run_handler → device_show_run_handler to match tool name
This commit is contained in:
parent
fbb8924a8e
commit
f7abb62603
@ -81,7 +81,7 @@ from .images import (
|
|||||||
install_images_handler,
|
install_images_handler,
|
||||||
)
|
)
|
||||||
from .device_config import (
|
from .device_config import (
|
||||||
device_config_send_handler, device_command_run_handler,
|
device_config_send_handler, device_show_run_handler,
|
||||||
vpcs_config_set_handler,
|
vpcs_config_set_handler,
|
||||||
)
|
)
|
||||||
from .nodes import (
|
from .nodes import (
|
||||||
@ -1405,7 +1405,7 @@ async def device_show_run(
|
|||||||
params = {"project_id": project_id, "device_configs": device_configs}
|
params = {"project_id": project_id, "device_configs": device_configs}
|
||||||
if template is not None:
|
if template is not None:
|
||||||
params["template"] = template
|
params["template"] = template
|
||||||
return await asyncio.to_thread(_run_handler_sync, device_command_run_handler, params)
|
return await asyncio.to_thread(_run_handler_sync, device_show_run_handler, params)
|
||||||
|
|
||||||
|
|
||||||
@mcp.tool()
|
@mcp.tool()
|
||||||
|
|||||||
@ -102,7 +102,7 @@ def device_config_send_handler(params: dict[str, Any], gns3_ctx: dict[str, Any])
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
def device_command_run_handler(params: dict[str, Any], gns3_ctx: dict[str, Any]) -> list[dict[str, Any]]:
|
def device_show_run_handler(params: dict[str, Any], gns3_ctx: dict[str, Any]) -> list[dict[str, Any]]:
|
||||||
"""Run read-only diagnostic (show) commands on network devices."""
|
"""Run read-only diagnostic (show) commands on network devices."""
|
||||||
project_id = params.get("project_id")
|
project_id = params.get("project_id")
|
||||||
device_configs = params.get("device_configs")
|
device_configs = params.get("device_configs")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user