[PR #120] [CLOSED] fix: grant write permissions for Copilot agent to post PR review comments #253

Closed
opened 2026-06-08 08:30:59 +00:00 by ryangr0 · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/webgrip/homelab-cluster/pull/120
Author: @Copilot
Created: 5/22/2026
Status: Closed

Base: mainHead: copilot/renovate-agent-review-118


📝 Commits (1)

📄 Description

The Copilot renovate-reviewer agent cannot post comments on PRs or issues — the GITHUB_TOKEN available in the agent environment has no write scope (Resource not accessible by integration HTTP 403 on both GraphQL addComment and REST POST .../issues/{n}/comments).

The github-writer MCP tools referenced in the agent instructions are not wired up or not available in the current Copilot agent environment, so reviews fall back to being printed in the session log rather than posted to the PR.

What needs to change

  • Token permissions — the Copilot agent environment needs a token with at minimum pull-requests: write (to comment on PRs) and issues: write (to close tracking issues). This is either a copilot-setup-steps.yml environment secret or a workflow-level permissions: grant.
  • github-writer MCP availability — confirm the MCP server providing add_issue_comment / update_issue_comment tools is registered and reachable in the agent's MCP config, otherwise the agent has no write path regardless of token scope.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/webgrip/homelab-cluster/pull/120 **Author:** [@Copilot](https://github.com/apps/copilot-swe-agent) **Created:** 5/22/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `copilot/renovate-agent-review-118` --- ### 📝 Commits (1) - [`ee61c37`](https://github.com/webgrip/homelab-cluster/commit/ee61c37231fd5cff57ac9706a8062235512a6ff7) Initial plan ### 📄 Description The Copilot renovate-reviewer agent cannot post comments on PRs or issues — the `GITHUB_TOKEN` available in the agent environment has no write scope (`Resource not accessible by integration` HTTP 403 on both GraphQL `addComment` and REST `POST .../issues/{n}/comments`). The `github-writer` MCP tools referenced in the agent instructions are not wired up or not available in the current Copilot agent environment, so reviews fall back to being printed in the session log rather than posted to the PR. ## What needs to change - **Token permissions** — the Copilot agent environment needs a token with at minimum `pull-requests: write` (to comment on PRs) and `issues: write` (to close tracking issues). This is either a `copilot-setup-steps.yml` environment secret or a workflow-level `permissions:` grant. - **`github-writer` MCP availability** — confirm the MCP server providing `add_issue_comment` / `update_issue_comment` tools is registered and reachable in the agent's MCP config, otherwise the agent has no write path regardless of token scope. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
ryangr0 2026-06-08 08:30:59 +00:00
Sign in to join this conversation.
No labels
pull-request
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
webgrip/homelab-cluster#253
No description provided.