Skip to content

fix(github): Reply to the thread root when in_reply_to names a reply - #2693

Merged
BYK merged 2 commits into
ref/github-api-helperfrom
fix/github-reply-thread-root
Nov 5, 2026
Merged

BYK merged 2 commits into
ref/github-api-helperfrom
fix/github-reply-thread-root

Conversation

@sentry-junior

@sentry-junior sentry-junior Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

Follow-up to #2690, from Bugbot's review comment.

POST /pulls/{n}/comments/{id}/replies accepts only the first comment of a thread. GitHub's docs say: "Replies to replies are not supported." Events often name a later reply, so github_commentOnPullRequest failed with 404 or 422 in the usual case.

Now, when in_reply_to is set, the tool reads the comment (github.pull.comment.get) and replies to its in_reply_to_id when it has one. A missing comment returns a PluginToolInputError.

This PR is stacked on #2692, which changes the same file.

--

View Session in Sentry

@sentry-junior
sentry-junior Bot added this pull request to stack #2694 November 4, 2026 22:20
@vercel

vercel Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
junior-docs Ready Ready Preview Nov 4, 2026 10:27pm UTC

Request Review

GitHub's review reply endpoint accepts only the first comment of a
thread. Events often name a later reply, so look up the comment and use
its in_reply_to_id when it has one.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 71be35e. Configure here.

GitHub sends in_reply_to_id: null on the first comment of a review thread.
The optional schema rejected it, so replies that named the root threw.
@BYK
BYK enabled stacked auto-merge (squash) November 5, 2026 10:00
@BYK
BYK merged commit aa58797 into main Nov 5, 2026
44 checks passed
@BYK
BYK deleted the fix/github-reply-thread-root branch November 5, 2026 10:01

This branch was successfully deployed

1 active deployment
Preview – junior-docs — 880acd8b Deployed Nov 4, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk: high PR risk score: high

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant