Title: `label_write` delete is missing `DestructiveHint: true` annotation · Issue #2723 · github/github-mcp-server · GitHub
Open Graph Title: `label_write` delete is missing `DestructiveHint: true` annotation · Issue #2723 · github/github-mcp-server
X Title: `label_write` delete is missing `DestructiveHint: true` annotation · Issue #2723 · github/github-mcp-server
Description: Describe the bug The label_write tool (pkg/github/labels.go) supports a delete method that deletes a label at the repository level via the deleteLabel GraphQL mutation. This permanently removes the label and all of its associations from ...
Open Graph Description: Describe the bug The label_write tool (pkg/github/labels.go) supports a delete method that deletes a label at the repository level via the deleteLabel GraphQL mutation. This permanently removes the...
X Description: Describe the bug The label_write tool (pkg/github/labels.go) supports a delete method that deletes a label at the repository level via the deleteLabel GraphQL mutation. This permanently removes the...
Opengraph URL: https://github.com/github/github-mcp-server/issues/2723
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`label_write` delete is missing `DestructiveHint: true` annotation","articleBody":"### Describe the bug\n\nThe `label_write` tool (`pkg/github/labels.go`) supports a `delete` method that deletes a label at the repository level via the `deleteLabel` GraphQL mutation. This permanently removes the label and all of its associations from every issue and PR in the repository.\n\nHowever, the tool's annotations only set `ReadOnlyHint: false`. It does **not** set `DestructiveHint: true`. As a result, MCP clients receive no destructive-operation signal for what is arguably the most destructive label operation available, and may not surface an appropriate confirmation prompt before executing it.\n\n### Expected behavior\n\n`label_write` should be annotated with `DestructiveHint: true` (at minimum when `method` is `delete`), so MCP clients can warn the user before a repository-wide label deletion.\n\n### Precedent in the codebase\n\nThe annotation discipline already exists elsewhere in the same package:\n- `remove_sub_issue` correctly sets `DestructiveHint: jsonschema.Ptr(true)`\n- The non-destructive issue label update (`update_issue_labels`) sets `DestructiveHint: jsonschema.Ptr(false)`\n\n`label_write` delete simply appears to have been missed.\n\n### Impact\n\nAn agent intending a minor change can trigger a repository-wide label deletion with no destructive-operation hint. Because deleting a label removes it from all issues/PRs, the associations cannot be automatically restored even if the label is recreated with the same name.\n\n### Version\n\nVerified against the open-source `github-mcp-server` v1.4.0 (latest release) and the hosted GitHub Copilot MCP endpoint at `api.githubcopilot.com/mcp/` (as of 2026-06-18). The missing annotation has been present since `label_write` was introduced (ref #312).","author":{"url":"https://github.com/pritesh-lahoti","@type":"Person","name":"pritesh-lahoti"},"datePublished":"2026-06-17T17:47:18.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/2723/github-mcp-server/issues/2723"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:ed50a61a-13fd-dbb8-db5b-7d81cb7c2c43 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9354:1DC30F:A4D1162:DD6C8D0:6A5E97E6 |
| html-safe-nonce | 3338a5c342da488b30a06e31fa6147b1b970404d405df4f9b75da2262fc9f516 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5MzU0OjFEQzMwRjpBNEQxMTYyOkRENkM4RDA6NkE1RTk3RTYiLCJ2aXNpdG9yX2lkIjoiMzM1NTUwMTMzNDE2NjkzNTUyNiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 2ac57535f2fbce8b67f4aaee0ae4375b22afacc28231c60234e94500f97b646c |
| hovercard-subject-tag | issue:4685715498 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/github/github-mcp-server/2723/issue_layout |
| twitter:image | https://opengraph.githubassets.com/3e4df8f5fdfcd7959def9894eff71bbd83d7645eded971b77419f04eb0d88bd2/github/github-mcp-server/issues/2723 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/3e4df8f5fdfcd7959def9894eff71bbd83d7645eded971b77419f04eb0d88bd2/github/github-mcp-server/issues/2723 |
| og:image:alt | Describe the bug The label_write tool (pkg/github/labels.go) supports a delete method that deletes a label at the repository level via the deleteLabel GraphQL mutation. This permanently removes the... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | pritesh-lahoti |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7c7e31acb6a895494e518b880f5ccf39604f7fa9a8f2f3c64145efc3b776256d |
| turbo-cache-control | no-preview |
| go-import | github.com/github/github-mcp-server git https://github.com/github/github-mcp-server.git |
| octolytics-dimension-user_id | 9919 |
| octolytics-dimension-user_login | github |
| octolytics-dimension-repository_id | 942771284 |
| octolytics-dimension-repository_nwo | github/github-mcp-server |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 942771284 |
| octolytics-dimension-repository_network_root_nwo | github/github-mcp-server |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 2d2ac9bdd71d5f53f2b731c9330677e38624e301 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width