Forgejo MCP: add update_issue tool for consolidated spec workflow #162

Open
opened 2026-03-26 03:49:14 +00:00 by forgejo_admin · 2 comments
Contributor

Type

Feature

Lineage

standalone — discovered while dogfooding scope review pipeline on forgejo_admin/dotfiles#1

Repo

forgejo_admin/claude-custom

User Story

As Betty Sue (main session agent)
I want to update a Forgejo issue's body via MCP
So that scope refinements can consolidate into the issue body instead of accumulating as comments

Context

The consolidated spec convention (from claude-custom#161) requires that after scope review refinements, the issue body gets rewritten with expanded scope. Comments document history (why scope changed), body is always the current spec. Currently the Forgejo MCP only has create_issue and comment_on_issue — no update_issue. This means Betty Sue can only post refinements as comments, creating the fragmented spec problem.

File Targets

  • ~/pal-e-docs-mcp/src/pal_e_docs_mcp/forgejo/tools.py (or equivalent) — add update_issue tool
  • ~/pal-e-docs-mcp/src/pal_e_docs_mcp/forgejo/client.py (or equivalent) — add PATCH /repos/{owner}/{repo}/issues/{index} API call

Files NOT to touch:

  • Issue creation or comment tools — those work fine

Acceptance Criteria

  • mcp__forgejo__update_issue(owner, repo, issue_number, body=..., title=...) available as MCP tool
  • Can update issue body without changing title (and vice versa)
  • Updated body appears correctly on Forgejo web UI

Test Expectations

  • Unit test: mock PATCH call, verify correct API endpoint and payload
  • Integration test: update a test issue body, verify via get
  • Run command: pytest tests/ -k test_update_issue

Constraints

  • Forgejo API: PATCH /repos/{owner}/{repo}/issues/{index} with JSON body {"body": "...", "title": "..."}
  • Follow existing tool patterns in the Forgejo MCP module
  • Both body and title should be optional (update only what's provided)

Checklist

  • PR opened
  • Tests pass
  • No unrelated changes
  • forgejo_admin/claude-custom#161 — scope review pipeline that requires this capability
  • forgejo_admin/dotfiles#1 — first ticket where the gap was discovered
### Type Feature ### Lineage standalone — discovered while dogfooding scope review pipeline on forgejo_admin/dotfiles#1 ### Repo `forgejo_admin/claude-custom` ### User Story As Betty Sue (main session agent) I want to update a Forgejo issue's body via MCP So that scope refinements can consolidate into the issue body instead of accumulating as comments ### Context The consolidated spec convention (from claude-custom#161) requires that after scope review refinements, the issue body gets rewritten with expanded scope. Comments document history (why scope changed), body is always the current spec. Currently the Forgejo MCP only has `create_issue` and `comment_on_issue` — no `update_issue`. This means Betty Sue can only post refinements as comments, creating the fragmented spec problem. ### File Targets - `~/pal-e-docs-mcp/src/pal_e_docs_mcp/forgejo/tools.py` (or equivalent) — add update_issue tool - `~/pal-e-docs-mcp/src/pal_e_docs_mcp/forgejo/client.py` (or equivalent) — add PATCH /repos/{owner}/{repo}/issues/{index} API call Files NOT to touch: - Issue creation or comment tools — those work fine ### Acceptance Criteria - [ ] `mcp__forgejo__update_issue(owner, repo, issue_number, body=..., title=...)` available as MCP tool - [ ] Can update issue body without changing title (and vice versa) - [ ] Updated body appears correctly on Forgejo web UI ### Test Expectations - [ ] Unit test: mock PATCH call, verify correct API endpoint and payload - [ ] Integration test: update a test issue body, verify via get - Run command: `pytest tests/ -k test_update_issue` ### Constraints - Forgejo API: `PATCH /repos/{owner}/{repo}/issues/{index}` with JSON body `{"body": "...", "title": "..."}` - Follow existing tool patterns in the Forgejo MCP module - Both body and title should be optional (update only what's provided) ### Checklist - [ ] PR opened - [ ] Tests pass - [ ] No unrelated changes ### Related - `forgejo_admin/claude-custom#161` — scope review pipeline that requires this capability - `forgejo_admin/dotfiles#1` — first ticket where the gap was discovered
Author
Contributor

Scope Review: NEEDS_REFINEMENT

Review note: review-365-2026-03-27

Duplicate of forgejo-mcp#15 (board item #360), which is filed on the correct repo.

Issues found:

  • Wrong repo: Issue says Repo: forgejo_admin/claude-custom but code lives in forgejo_admin/forgejo-mcp
  • Wrong file paths: Both file targets reference ~/pal-e-docs-mcp/src/pal_e_docs_mcp/forgejo/ which does not exist. Correct paths are ~/forgejo-mcp/src/forgejo_mcp/tools/workflows.py and ~/forgejo-mcp/tests/
  • No client.py needed: The SDK already has issue_edit_issue(owner, repo, index, *, title=None, body=None, ...) — no new client code required
  • Duplicate: forgejo_admin/forgejo-mcp#15 covers identical scope on the correct repo

Recommend: close this issue as duplicate of forgejo-mcp#15, remove board item #365, and consolidate scope into #360.

## Scope Review: NEEDS_REFINEMENT Review note: `review-365-2026-03-27` **Duplicate of forgejo-mcp#15** (board item #360), which is filed on the correct repo. Issues found: - **Wrong repo**: Issue says `Repo: forgejo_admin/claude-custom` but code lives in `forgejo_admin/forgejo-mcp` - **Wrong file paths**: Both file targets reference `~/pal-e-docs-mcp/src/pal_e_docs_mcp/forgejo/` which does not exist. Correct paths are `~/forgejo-mcp/src/forgejo_mcp/tools/workflows.py` and `~/forgejo-mcp/tests/` - **No client.py needed**: The SDK already has `issue_edit_issue(owner, repo, index, *, title=None, body=None, ...)` — no new client code required - **Duplicate**: `forgejo_admin/forgejo-mcp#15` covers identical scope on the correct repo Recommend: close this issue as duplicate of forgejo-mcp#15, remove board item #365, and consolidate scope into #360.
Author
Contributor

Closing — Duplicate

Scope review (review-365-2026-03-27) found this is a duplicate of forgejo-mcp#15 filed on the wrong repo. The canonical ticket is forgejo-mcp#15 (board item #360).

## Closing — Duplicate Scope review (`review-365-2026-03-27`) found this is a duplicate of `forgejo-mcp#15` filed on the wrong repo. The canonical ticket is `forgejo-mcp#15` (board item #360).
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
ldraney/claude-custom#162
No description provided.