Skip to content

refactor(@angular/cli): migrate MCP zoneless tool to host abstraction#33133

Open
clydin wants to merge 1 commit intoangular:mainfrom
clydin:refactor/mcp-zoneless-host
Open

refactor(@angular/cli): migrate MCP zoneless tool to host abstraction#33133
clydin wants to merge 1 commit intoangular:mainfrom
clydin:refactor/mcp-zoneless-host

Conversation

@clydin
Copy link
Copy Markdown
Member

@clydin clydin commented May 5, 2026

Migrate the zoneless migration tool to use the Host abstraction for file system operations including reading files, checking stats, and globbing. This ensures that the tool adheres to the allowed roots configured in the MCP server. By removing direct dependencies on native Node.js fs modules, the tool now benefits from the centralized injection and restriction model provided by the Host implementation.

@clydin clydin force-pushed the refactor/mcp-zoneless-host branch from 45dc998 to 225778b Compare May 5, 2026 20:46
@clydin clydin marked this pull request as ready for review May 5, 2026 20:47
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the zoneless migration tool to use a Host abstraction for file system operations instead of direct node:fs calls. This involves updating several functions and tests to accept and utilize the Host interface. A review comment identifies a potential type mismatch in the Host implementation following the update of the readFile signature to use BufferEncoding.

Comment thread packages/angular/cli/src/commands/mcp/host.ts
Migrate the zoneless migration tool to use the Host abstraction for file system operations including reading files, checking stats, and globbing. This ensures that the tool adheres to the allowed roots configured in the MCP server. By removing direct dependencies on native Node.js fs modules, the tool now benefits from the centralized injection and restriction model provided by the Host implementation.
@clydin clydin force-pushed the refactor/mcp-zoneless-host branch from 225778b to 1671504 Compare May 5, 2026 20:54
@clydin clydin added action: review The PR is still awaiting reviews from at least one requested reviewer target: minor This PR is targeted for the next minor release labels May 5, 2026
@clydin clydin requested a review from alan-agius4 May 5, 2026 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action: review The PR is still awaiting reviews from at least one requested reviewer area: @angular/cli target: minor This PR is targeted for the next minor release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant