Skip to content

Add planning statuses to issues - #3958

Open
MichelleGrounds wants to merge 19 commits into
mainfrom
mg/issues-statuses
Open

MichelleGrounds wants to merge 19 commits into
mainfrom
mg/issues-statuses

Conversation

@MichelleGrounds

@MichelleGrounds MichelleGrounds commented Nov 26, 2026 •

Copy link
Copy Markdown

Summary

Expose GitHub issue planning statuses through the MCP server.

Why

Make issue planning workflows available to MCP clients.
Fixes #4004.

What changed

  • Add issue status reading, filtering, creation, and updates.
  • Support setting an initial status in the issue creation UI; update docs and bundled skills.

MCP impact

  • No tool or API changes
  • Tool schema or behavior changed — issue status can now be read, filtered, and set.
  • New tool added — update_issue_status.

Prompts tested (tool changes only)

  • No prompt-level tests run; automated tests passed.

Security / limits

  • No security or limits impact
  • Auth / permissions considered
  • Data exposure, filtering, or token/size limits considered

Tool renaming

  • I am renaming tools as part of this PR (e.g. a part of a consolidation effort)
    • I have added the new tool aliases in deprecated_tool_aliases.go
  • I am not renaming tools as part of this PR

Lint & tests

  • Linted locally with ./script/lint
  • Tested locally with ./script/test

Docs

  • Not needed
  • Updated (README / docs / examples)

Skills

  • Updated relevant skills or confirmed no bundled skill applies

Comment thread pkg/github/issue_status.go Resolved
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Comment thread pkg/github/issue_status.go Resolved
Comment thread pkg/github/issue_status.go Resolved
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Comment thread pkg/github/issue_status.go Resolved
MichelleGrounds and others added 3 commits November 26, 2026 14:30
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Auto-generated by license-check workflow
@MichelleGrounds
MichelleGrounds marked this pull request as ready for review November 27, 2026 10:04
@MichelleGrounds
MichelleGrounds requested a review from a team as a code owner November 27, 2026 10:04
Copilot AI adaptive review requested due to automatic review settings November 27, 2026 10:04
Auto-generated by license-check workflow

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unvalidated repository coordinates can redirect authenticated PATCH and POST requests to unintended API paths, creating a critical security risk.

3 open issues
What changed in this PR

Adds issue planning status support to the GitHub MCP Server, enabling clients to read statuses, set an initial status, and update existing issues.

Changes:

  • Adds update_issue_status, including confirmation for closing statuses and duplicate-issue handling.
  • Extends issue creation tools and the creation form with initial status selection.
  • Updates documentation, bundled skills, schemas, tests, and license inventories.
File Description
ui/​src/​apps/​issue-write/​App.tsx Adds initial status selection to the creation form.
third-party-licenses.windows.md Corrects a dependency license link.
third-party-licenses.linux.md Corrects a dependency license link.
third-party-licenses.darwin.md Splits license inventories by architecture.
README.md Documents status workflows and tool parameters.
pkg/​skills/​catalog/​tools.go Adds status updates to the triage skill’s optional tools.
pkg/​skills/​catalog/​skills/​issue-backlog-triage/​SKILL.md Explains status filtering and transitions.
pkg/​skills/​catalog/​skills/​issue-authoring/​SKILL.md Documents initial status and partial-write handling.
pkg/​http/​server_test.go Checks search descriptions include status guidance.
pkg/​github/​typed_issue_outputs_test.go Updates typed issue expectations and feature selection.
pkg/​github/​typed_consolidated_issue_outputs_test.go Tests status availability, contracts, reads, and creation.
pkg/​github/​typed_consolidated_issue_enrichment_test.go Includes status in enriched output expectations.
pkg/​github/​tools.go Registers update_issue_status.
pkg/​github/​search_semantic_test.go Updates search description assertions.
pkg/​github/​issues.go Integrates status reading, creation, and search guidance.
pkg/​github/​issues_test.go Tests status schema and form routing.
pkg/​github/​issues_granular.go Supports status in granular issue creation.
pkg/​github/​issue_status.go Implements status validation, updates, and API helpers.
pkg/​github/​granular_tools_test.go Tests status transitions, validation, and unapplied statuses.
pkg/​github/​granular_issue_types.go Adds status to granular creation inputs.
pkg/​github/​consolidated_issue_types.go Adds status to consolidated inputs and outputs.
pkg/​github/​__toolsnaps__/​update_issue_status.snap Records the new tool contract.
pkg/​github/​__toolsnaps__/​search_issues.snap Records status-filter guidance.
pkg/​github/​__toolsnaps__/​issue_write.snap Records the initial status parameter.
pkg/​github/​__toolsnaps__/​issue_read.snap Records the nullable status output.
pkg/​github/​__toolsnaps__/​create_issue.snap Records granular creation’s status parameter.
docs/​feature-flags.md Documents status for granular creation.

Review effort: Balanced (adaptive)

Comment thread pkg/github/issue_status.go Resolved
Comment thread pkg/github/issue_status.go Resolved
Comment thread pkg/github/issue_status.go Resolved
Validate repository path segments, allow public-repo scope access, and report when requested creation status is not applied.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Comment thread pkg/github/issue_status.go Resolved
Comment thread pkg/github/issues.go Resolved
Comment thread pkg/github/issue_status.go Resolved
MichelleGrounds and others added 5 commits December 1, 2026 10:33
Validate and escape owner and repo in getIssue before building the REST
path, so crafted coordinates cannot change the requested URL.

Remove confirm_close from update_issue_status and set DestructiveHint to
false, matching update_issue_state and issue_write, which close issues
without a server-side confirmation step.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Auto-generated by license-check workflow
Auto-generated by license-check workflow
Comment thread pkg/github/issues.go
if err != nil {
return ghErrors.NewGitHubGraphQLErrorResponse(ctx, "failed to resolve planning status", err), nil, nil
}
input.StatusID = &statusID

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: Check the status GitHub actually applied to the sub-issue. GitHub documents on CreateIssueInput.statusId that if the caller lacks permission to set the status, it ignores the field and creates the issue in Backlog. This mutation only reads the ID and URL, so a caller requesting In review gets an unqualified success. When a status is requested, please select the created issue’s status and report any mismatch with the issue URL. Keep the existing mutation selection for calls without a status so they still work on older schemas.

Comment thread pkg/github/issues.go
}

if err := unappliedIssueStatusError(status, issue); err != nil {
return ghErrors.NewGitHubAPIErrorResponse(ctx, "issue created but requested status was not applied", resp, err), nil, nil

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: Don’t leave Create enabled after the issue already exists. This error follows a successful POST. The issue-write form handles result.isError by displaying the text and re-enabling Create. If the user changes the status and submits again, it creates a second issue. Please return the created issue’s ID and URL with a machine-readable status warning, and have the form show the existing issue and warning instead of offering another create.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Insiders Feedback: reading and updating new first-class Issue Status

4 participants