Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Add update_pull_request_comment and delete_pull_request_comment tools

オープン
#2,448 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
68/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
静か
技術スタック
github, go
領域
api, tooling

調査の方向性

まず、既存の add_reply_to_pull_request_comment ツールと、その GitHub API リクエストパターンを特定します。次に、指定された REST エンドポイントとパラメーターを使用して、対応する更新用および削除用のツールを追加し、それぞれが説明どおり認証済みユーザーのコメントを対象とし、更新時に要求された body をサポートすることを確認します。

索引モデルが issue の本文から書いたものです。

説明

Describe the feature or problem you'd like to solve

The MCP server provides add_reply_to_pull_request_comment for PR review comments, but there is no way to edit or delete an existing review comment. The only available mutation is adding a new reply underneath an existing comment.

When an agent needs to correct or retract a review comment it previously posted, the current workaround is to post a new reply — leaving the stale original visible and creating thread noise. The alternative is falling back to gh api with PATCH/DELETE on /repos/{owner}/{repo}/pulls/comments/{id}, bypassing the MCP server entirely.

Proposed solution

Add two new tools that map to the existing GitHub REST API endpoints:

update_pull_request_comment
  • REST API: PATCH /repos/{owner}/{repo}/pulls/comments/{comment_id}
  • Parameters: owner, repo, comment_id (number), body (string — new body text)
  • Auth constraint: Can only update comments authored by the authenticated user
  • Equivalent gh command: gh api repos/{owner}/{repo}/pulls/comments/{id} -X PATCH -f body="..."
delete_pull_request_comment
  • REST API: DELETE /repos/{owner}/{repo}/pulls/comments/{comment_id}
  • Parameters: owner, repo, comment_id (number)
  • Auth constraint: Can only delete comments authored by the authenticated user
  • Equivalent gh command: gh api repos/{owner}/{repo}/pulls/comments/{id} -X DELETE

Both endpoints are already documented in the GitHub REST API and require no new upstream features.

Additional context

This gap caused a real-world problem: an agent posted review replies that should have been edits to the original comments. The discussion_r{N} URL identifier ≠ the API comment id (a separate but related confusion — see #2235 for a different comment-reading gap), and without an edit tool the agent defaulted to the only mutation available — add_reply — producing thread noise instead of correcting the original.

Having edit/delete tools also enables agents to clean up their own mistakes programmatically, which is important for production reliability.

主要言語
Go
スター
33.1k
フォーク
5k
平均マージ
2日 1時間
マージ済み PR(30日)
25

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

github/github-mcp-server のほかの issue

github/github-mcp-server の issue をすべて見る

似ている issue

Go の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。