Skip to content

Link the issue a pull request description names when GitHub did not - #138

Open
rtibbles wants to merge 1 commit into
pr-issue-assignmentfrom
pr-link-reference
Open

rtibbles wants to merge 1 commit into
pr-issue-assignmentfrom
pr-link-reference

Conversation

@rtibbles

@rtibbles rtibbles commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Pull requests to a non-default branch never link the issue their closing keyword names, so they are labelled unlinked and closed.
  • Link those keyword references the way GitHub does on the default branch.
  • When nothing is linked, link the one mentioned issue assigned to the author, ask which when several are, and tell an unlinked author the issue comes first.

References

Closes #112. Stacked on: #136. Unlinked keyword: learningequality/kolibri#15763.
Mutation run with the LE bot app token: learningequality/test-actions#104.

Reviewer guidance

JS tests pass on CI.

AI usage

Used Claude Code to revise the issue and implement the parsing, linking and replies. Verified with the full test suite, ESLint, Prettier, and the mutation run in test-actions.

🤖 Generated with Claude Code

https://claude.ai/code/session_013PjXpbp1QSbkpzvnRwm7yv

@rtibbles
rtibbles requested a review from rtibblesbot November 7, 2026 19:56
@rtibblesbot

rtibblesbot commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

🟡 Waiting for changes

Outcome: reviewed 9614aa9

Last updated: 2026-11-10 08:47 UTC

@rtibblesbot rtibblesbot 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.

PR #138: one suggestion inline. Linking flow matches #112. Reply tests cover each case through a fake github.graphql. CI passing.

  • suggestion: a #N above GraphQL's 32-bit Int fails the whole reference query (inline).

Next step: Needs a full code review by a human engineer.

  • Workflow steps changed: .github/workflows/contributor-pr-reply.yml.
  • Confirm an assigned issue the author only mentions ("part of #7") should get a closing link, so that merging closes it.
  • Confirm the app token's issues: write permission allows addCloseIssueReferences, since the PR says this has not been tested.

Written by rtibblesbot, an LLM-based coding agent.

Comment thread scripts/utils.js Resolved
@rtibbles
rtibbles added this pull request to stack #137 November 10, 2026 08:07
@rtibbles
rtibbles force-pushed the pr-link-reference branch 2 times, most recently from 679097d to fdf872e Compare November 10, 2026 08:22
- Off the default branch, link every issue after a closing keyword, as GitHub would on it
- Otherwise link the one mentioned issue assigned to the author, and name it in the reply
- Name several assigned mentions and ask which one, without linking
- Tell an unlinked author the issue comes first

Closes #112

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013PjXpbp1QSbkpzvnRwm7yv

@rtibblesbot rtibblesbot 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.

PR #138: a single assigned candidate is still never linked, contrary to #112 (inline).

1 of 2 prior findings resolved. CI passing. Commits pushed after the review passes were not reviewed. The open finding is confirmed at fdf872e.

  • blocking: a single assigned candidate is never linked, contrary to #112 (inline).
Prior-finding status

UNADDRESSED — scripts/contributor-pr-reply.js:82 — single assigned candidate is never linked
RESOLVED — scripts/utils.js:327 — #N above 32-bit Int fails the whole reference query

Next step: Needs a full code review by a human engineer.

  • Workflow steps changed: .github/workflows/contributor-pr-reply.yml.
  • Decide whether a mention-only reference to one assigned issue is auto-linked (as #112 specifies) or only asked about (as this PR does).
  • Check that auto-linking via addClosingIssueReference cannot close the wrong issue when the PR body mentions an issue in passing.

Written by rtibblesbot, an LLM-based coding agent.

Comment thread scripts/pull-request-link.js Resolved

@rtibblesbot rtibblesbot 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.

PR #138: both prior findings are resolved. No new findings. CI is passing.

Prior-finding status

RESOLVED — scripts/utils.js:327 — #N above 2147483647 fails the whole reference query
RESOLVED — scripts/pull-request-link.js:23 — one open candidate assigned to the author is never linked

Next step: Needs a full code review by a human engineer.

  • Workflow steps changed: .github/workflows/contributor-pr-reply.yml.
  • Check that linking an issue named in the PR body is what #112 intended, for an issue assigned to the author but not referenced with a closing keyword.
  • Check the reply that asks contributors which issue they mean when several are assigned to them; its wording will be copied across repositories.

Written by rtibblesbot, an LLM-based coding agent.

@rtibbles
rtibbles marked this pull request as ready for review November 10, 2026 13:06
@rtibbles
rtibbles requested review from a team and leq-bot November 10, 2026 13:06
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.

Link a referenced issue for its assignee, and ask for the issue first when we cannot

2 participants