From 5649c66c815ff0fb51a642555a5c19c3238ed096 Mon Sep 17 00:00:00 2001
From: Charles Lyding <19598772+clydin@users.noreply.github.com>
Date: Wed, 22 Jul 2026 21:30:00 -0400
Subject: [PATCH] fix(@angular/cli): update MCP devserver tool names to conform
to spec regex
MCP tool names must adhere to the regular expression ^[a-zA-Z0-9_-]+$. This commit updates devserver.start, devserver.stop, and devserver.wait_for_build to use underscores (devserver_start, devserver_stop, devserver_wait_for_build) and updates all corresponding tool references and documentation across the MCP command package.
---
.../mcp/tools/devserver/devserver-start.ts | 16 ++++++++--------
.../mcp/tools/devserver/devserver-stop.ts | 4 ++--
.../tools/devserver/devserver-wait-for-build.ts | 10 +++++-----
.../tools/run-target/generic-target-strategy.ts | 2 +-
.../commands/mcp/tools/run-target/run-target.ts | 2 +-
5 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-start.ts b/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-start.ts
index 8f5548f14019..4e2155f500b7 100644
--- a/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-start.ts
+++ b/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-start.ts
@@ -93,29 +93,29 @@ export const DEVSERVER_START_TOOL: McpToolDeclaration<
typeof devserverStartToolInputSchema.shape,
typeof devserverStartToolOutputSchema.shape
> = declareTool({
- name: 'devserver.start',
+ name: 'devserver_start',
title: 'Start Development Server',
description: `
-Starts the Angular development server ("ng serve") as a background process. Follow this up with "devserver.wait_for_build" to wait until
+Starts the Angular development server ("ng serve") as a background process. Follow this up with "devserver_wait_for_build" to wait until
the first build completes.
* This tool manages development servers by itself. It maintains at most a single dev server instance for each project in the monorepo.
* This is an asynchronous operation. Subsequent commands can be ran while the server is active.
-* Use 'devserver.stop' to gracefully shut down the server and access the full log output.
+* Use 'devserver_stop' to gracefully shut down the server and access the full log output.
* **Keeping the Server Alive**: It is often better to keep the server alive between tool calls if you expect the user to request more
changes or run more tests, as it saves time on restarts and maintains the file watcher state. You must still call
- 'devserver.wait_for_build' after every change to see whether the change was successfully built and be sure that that app was updated.
+ 'devserver_wait_for_build' after every change to see whether the change was successfully built and be sure that the app was updated.
* **Consistent Ports**: If making multiple calls, it is recommended to reuse the port you got from the first call for subsequent ones.
`,
diff --git a/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-stop.ts b/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-stop.ts
index 1c90bd9ecd98..669160695194 100644
--- a/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-stop.ts
+++ b/packages/angular/cli/src/commands/mcp/tools/devserver/devserver-stop.ts
@@ -54,11 +54,11 @@ export const DEVSERVER_STOP_TOOL: McpToolDeclaration<
typeof devserverStopToolInputSchema.shape,
typeof devserverStopToolOutputSchema.shape
> = declareTool({
- name: 'devserver.stop',
+ name: 'devserver_stop',
title: 'Stop Development Server',
description: `
-Stops a running Angular development server ("ng serve") that was started with the "devserver.start" tool.
+Stops a running Angular development server ("ng serve") that was started with the "devserver_start" tool.