Allow loading external content during review#6086
Draft
padenot wants to merge 11 commits into
Draft
Conversation
0048d1b to
fac1b71
Compare
Adds the moz.tools MCP server to the Anthropic client so the agent can call mozilla__ tools during review. URL is overridable via BUGBUG_MOZ_MCP_URL.
LocalPatch wraps a raw unified diff string as a first-class Patch so it can flow through the review pipeline without a Phabricator backing. It accepts an optional commit_message and parses from it: the patch title (first line), description (remaining lines), bug ID (Bug NNN), and Differential Revision URL, and date if present in the format-patch header. On the MCP server side, patch_review now accepts optional diff= and commit_message= parameters alongside patch_url=, and a new patch_review_tool exposes the same logic as an @mcp.tool(). A shared _patch_review_impl handles both cases, using a lighter CodeReviewTool instance (no DB, no suggestion filtering) for local diffs. LOCAL_SYSTEM_PROMPT_TEMPLATE uses searchfox-cli and local agent tools instead of the agent-specific expand_context and searchfox tools.
2d67a7c to
8c4fe6d
Compare
8c4fe6d to
cab6ec7
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.