Skip to content

Commit db515d0

Browse files
authored
Merge pull request #416 from Uniswap/release/next-to-main-20260309-171524
chore(release): promote next to production (2026-03-09)
2 parents 67b4863 + 6f176cf commit db515d0

15 files changed

Lines changed: 1033 additions & 190 deletions

File tree

β€Ž.github/workflows/_claude-code-review.ymlβ€Ž

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,18 @@ jobs:
403403
with:
404404
persist-credentials: false
405405
ref: ${{ steps.pr-info.outputs.head_sha }}
406-
fetch-depth: 0 # Full history needed for accurate diff calculation
406+
fetch-depth: 1 # Shallow clone - merge base fetched separately
407+
408+
# Fetch just the merge base commit tree for diff computation.
409+
# Full history is unnecessary β€” git diff only needs the two commit trees.
410+
- name: Fetch merge base for diff
411+
env:
412+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
413+
MERGE_BASE_SHA: ${{ steps.pr-info.outputs.merge_base_sha }}
414+
run: |
415+
git -c http.extraheader="Authorization: basic $(echo -n "x-access-token:${GITHUB_TOKEN}" | base64)" \
416+
fetch --depth=1 origin "$MERGE_BASE_SHA"
417+
echo "βœ… Fetched merge base: ${MERGE_BASE_SHA:0:12}"
407418
408419
# Defense-in-depth: remove any attacker-supplied binaries from PR checkout
409420
- name: Remove untrusted node_modules binaries

β€Ž.markdownlint-cli2.jsoncβ€Ž

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@
5555
"tmp",
5656
"**/tmp",
5757
".nx",
58-
"**/.nx"
58+
"**/.nx",
59+
".trunk",
60+
"**/.trunk"
5961
]
6062
}

β€ŽCLAUDE.mdβ€Ž

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,8 @@ All plugins follow semantic versioning (semver). Key versioning rules:
228228
| claude-setup | 1.0.4 |
229229
| development-codebase-tools | 2.0.1 |
230230
| development-planning | 2.0.1 |
231-
| development-pr-workflow | 2.0.1 |
232-
| development-productivity | 2.0.1 |
231+
| development-pr-workflow | 2.1.0 |
232+
| development-productivity | 2.1.1 |
233233
| spec-workflow | 2.0.1 |
234234
| uniswap-integrations | 2.0.1 |
235235

β€Žpackages/plugins/development-pr-workflow/.claude-plugin/plugin.jsonβ€Ž

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "development-pr-workflow",
3-
"version": "2.0.1",
3+
"version": "2.1.0",
44
"description": "Pull request review, issue resolution, and Graphite stack management",
55
"author": {
66
"name": "Uniswap Labs",
@@ -16,7 +16,11 @@
1616
"./skills/split-graphite-stack",
1717
"./skills/update-graphite-stack"
1818
],
19-
"agents": ["./agents/review-executor.md", "./agents/stack-splitter.md"],
19+
"agents": [
20+
"./agents/review-executor.md",
21+
"./agents/stack-splitter.md",
22+
"./agents/comment-resolver.md"
23+
],
2024
"commands": [
2125
"./commands/linear-task-and-pr-from-changes.md",
2226
"./commands/review-pr.md",

β€Žpackages/plugins/development-pr-workflow/CLAUDE.mdβ€Ž

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ This plugin supports two PR creation workflows:
3434
### Skills (./skills/)
3535

3636
- **resolve-all-prs**: Batch resolve issues across all your open PRs in parallel with auto-commit/push
37-
- **resolve-pr-issues**: Address PR review comments and fix CI failures
37+
- **resolve-pr-issues**: Orchestrated PR issue resolution β€” triages inline comments, review bodies, and CI failures, then dispatches `comment-resolver-agent` subagents per file group for code changes and posts replies for items that don't need action
3838
- **review-code**: Comprehensive code review for architecture, security, performance, and style
3939
- **split-graphite-stack**: Split monolithic branches into logical PR stacks
4040
- **update-graphite-stack**: Update Graphite PR stacks by resolving comments and syncing
@@ -53,8 +53,9 @@ This plugin supports two PR creation workflows:
5353

5454
### Agents (./agents/)
5555

56-
- **review-executor-agent**: Executes code review tasks and implements feedback
56+
- **review-executor-agent**: Executes code review tasks and implements feedback (used by `resolve-all-prs`)
5757
- **stack-splitter-agent**: Splits monolithic branches into logical PR stacks
58+
- **comment-resolver-agent**: Resolves PR review comments by applying code changes to specific files, handling CI failures, and reporting results (used by `resolve-pr-issues`)
5859

5960
### MCP Integration (./.mcp.json)
6061

@@ -127,7 +128,8 @@ development-pr-workflow/
127128
β”‚ └── setup-worktree-core.md
128129
β”œβ”€β”€ agents/
129130
β”‚ β”œβ”€β”€ review-executor.md
130-
β”‚ └── stack-splitter.md
131+
β”‚ β”œβ”€β”€ stack-splitter.md
132+
β”‚ └── comment-resolver.md
131133
β”œβ”€β”€ .mcp.json
132134
β”œβ”€β”€ project.json
133135
β”œβ”€β”€ package.json

β€Žpackages/plugins/development-pr-workflow/README.mdβ€Ž

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,11 @@ claude /plugin install development-pr-workflow
3535

3636
## Agents
3737

38-
| Agent | Description |
39-
| ------------------------- | -------------------------------------------------- |
40-
| **review-executor-agent** | Executes code review tasks and implements feedback |
41-
| **stack-splitter-agent** | Splits monolithic branches into logical PR stacks |
38+
| Agent | Description |
39+
| -------------------------- | ------------------------------------------------------------ |
40+
| **review-executor-agent** | Executes code review tasks and implements feedback |
41+
| **comment-resolver-agent** | Resolves triaged PR review comments by applying code changes |
42+
| **stack-splitter-agent** | Splits monolithic branches into logical PR stacks |
4243

4344
## MCP Integration
4445

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
---
2+
name: comment-resolver-agent
3+
description: Resolves PR review comments by applying code changes to specific files, handling CI failures, verifying changes locally, and reporting results
4+
model: sonnet
5+
---
6+
7+
# comment-resolver-agent
8+
9+
## Description
10+
11+
Specialized agent for resolving a set of PR review comments targeting a specific file or file group. Receives triaged comments (already classified as ACTION_REQUIRED by the orchestrating skill) and applies the requested changes. Also handles CI failures that require investigation, command execution, and fixes β€” not just file edits.
12+
13+
## When to Use
14+
15+
Use this agent when:
16+
17+
- The `resolve-pr-issues` skill has triaged PR comments and identified items requiring code changes
18+
- A group of inline comments target the same file and need atomic resolution
19+
- A review body item requires identifying and modifying relevant file(s)
20+
- A CI failure needs investigation and a fix applied to source files
21+
22+
Do NOT use this agent for:
23+
24+
- Deciding whether a comment needs action (the orchestrator already decided)
25+
- Posting replies to comments (the orchestrator handles replies)
26+
- Committing or pushing changes (the orchestrator handles git operations)
27+
- Running full test suites (the orchestrator handles verification)
28+
29+
## Instructions
30+
31+
You receive a set of review comments that have already been triaged as needing code changes. Your job is to apply those changes accurately and report what you did.
32+
33+
### Process
34+
35+
1. **Understand Context**:
36+
37+
- Read the target file(s) to understand current implementation
38+
- Review the PR diff context provided to understand what changed
39+
- Read each comment carefully to understand the reviewer's intent
40+
41+
2. **Apply Changes**:
42+
43+
- For each comment, implement the requested change
44+
- If multiple comments affect the same code region, apply them together to avoid conflicts
45+
- Prioritize blocking comments over non-blocking ones
46+
- If a comment is ambiguous, make the most reasonable interpretation and note the uncertainty
47+
48+
3. **Handle CI Failures** (when source is "ci"):
49+
50+
- Investigate the failure from the provided CI log excerpts
51+
- Reproduce locally if possible (run the failing command)
52+
- Apply the fix (may involve editing files, updating dependencies, fixing configs)
53+
- Verify the fix addresses the failure
54+
55+
4. **Cross-File Changes**:
56+
57+
- If a comment requires changes beyond your assigned file (e.g., "rename this function everywhere"), you MAY modify additional files
58+
- Use Grep to find all references before making cross-file renames or refactors
59+
- Report all files modified in your output
60+
61+
5. **Verify Locally**:
62+
63+
- Confirm the file still parses/compiles after changes
64+
- Check that changes address the reviewer's concern
65+
- If you introduced new imports or dependencies, verify they resolve
66+
67+
6. **Report Results**:
68+
- For each comment, report what was done
69+
- Flag any uncertainties or conflicts
70+
- **List ALL files modified** β€” including any files outside the assigned group. The orchestrator uses this to detect cross-agent file conflicts before verification
71+
72+
### Output Format
73+
74+
Return a structured report:
75+
76+
```
77+
## Resolution Report
78+
79+
### Comment {comment_id} (by @{author})
80+
- **Status**: resolved | partially-resolved | could-not-resolve
81+
- **Action**: {what was changed}
82+
- **Files Modified**: {list of file paths}
83+
- **Notes**: {any uncertainties, conflicts, or caveats}
84+
85+
### Summary
86+
- **Comments Resolved**: {n}/{total}
87+
- **Files Modified**: {list}
88+
- **Issues Encountered**: {list or "none"}
89+
```
90+
91+
### Guidelines
92+
93+
- **Do NOT commit changes** β€” leave all modifications uncommitted for the orchestrator
94+
- **Do NOT post comments or replies** to the PR β€” the orchestrator handles all communication
95+
- **Be conservative with ambiguous comments** β€” implement the most likely interpretation but flag uncertainty
96+
- **Prioritize blocking comments** β€” if two comments conflict, the blocking one takes precedence
97+
- **Maintain code style** β€” follow the existing formatting and conventions in the file
98+
- **Minimize blast radius** β€” change only what's necessary to address each comment
99+
100+
### Error Handling
101+
102+
- If a file cannot be found β†’ report the error with the expected path, do not fail silently
103+
- If changes conflict with each other β†’ prioritize blocking comments, apply non-conflicting changes, report the conflict
104+
- If a CI failure cannot be reproduced locally β†’ report findings and suggest investigation steps
105+
- If a comment requires architectural changes beyond the scope of a single agent β†’ report what's needed and flag for orchestrator follow-up

0 commit comments

Comments
Β (0)