learningequality / learningequality/.github

Create process for unplanned work and automate PR handling based on linked issue assignment

Open
#67 1 comment 0 reactions 1 assignee View on GitHub

@akolson is already working on this.

Since Apr 2, 2026.

Dominant language
JavaScript
Stars
1
Forks
7
PR merge metrics
No merged PRs in 30d

Description

This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.

See the note below for the process part.

Overview

Add two new automated behaviors for community pull requests, both triggered when a PR is opened:

Auto-close PR for issues assigned to someone else

When a community contributor opens a PR linked to an issue that is already assigned to someone else, the PR is closed, LE bot posts an info message, and #support-dev-notifications receive a notification).

Auto-review & community review for assigned contributors

When a community contributor opens a PR linked to an issue they are assigned to, rtibblesbot review is automatically requested and community-review label added.

Guidance

contributor-pr-reply workflow triggers on pull_request_target: [opened] for community contributors and posts BOT_MESSAGE_PULL_REQUEST. It will likely make sense to turn it into a more general workflow for handling community pull requests that would be enhanced with the 2 new behaviors.

The Change

Auto-close

When a community PR is opened, if a linked issue is found and that issue is assigned to someone other than the PR author:

  • The LE bot posts a closing message
  • The PR is closed & support-dev-notifications Slack channel receives an auto-close notification
  • The regular BOT_MESSAGE_PULL_REQUEST message is not sent (and support-dev-notifications doesn't receive the related notification)

There should be no changes to the automated contributions tracking spreadsheet - it should contain all closed, including auto-closed, PRs.

Auto-review & community review

When a community PR is opened, if a linked issue is found and the PR author is assigned to that issue:

  • rtibblesbot is automatically requested for review
  • The community-review label is added

contributor-pr-reply doesn't need to send info bot messages after rtibblesbot review requested and community-review label added. It should only perform actions of request and label (Info messages are already sent by another workflows, review-requested and pull-request-label, which allows more flexibility as info messages will work if review request and label added manually. This needs to be preserved.)

Out of Scope

PRs with no linked issue, or with a linked issue that has no assignee

  • No auto-close or auto-review PRs
  • Receive only the (already functioning) BOT_MESSAGE_PULL_REQUEST message

This is a tradeoff related to the fact that we currently make an exceptions from time to time & allow for such PRs. This will mean that (1) we will need to close some PRs manually, (2) for contributors who forget to link their issue we will need to request community-review and rtibblesbot review manually (to avoid triggering reviews on PRs that may be later closed by us). It can be revisited & simplified in a follow-up in case we decide to auto-close all unasigned PRs (still needs decision). In that way we could always either auto-review or auto-close (with a bot note that (a) the auto-close may be a mistake if the issue wasn't linked properly using closing keywords in the PR description + instruction to open a new PR with properly linked issue; (b) redirect to a place where to discuss the suggestion at first).

Acceptance Criteria

Auto close:

  • PRs opened linked to issues assigned to someone other than the PR author are autoclosed
  • A bot message is posted on the PR explaining why
  • The support-dev-notifications channel receives a notification of the autoclosure
  • Other automatic behaviours for community contributor PRs should not fire

Auto-review/label:

  • Bot review is auto requested on PRs linked to an issue assigned to the author
  • Follow up bot review message is removed
  • Community review label is auto applied on PRs linked to an issue assigned to the author
  • Follow up community review message is removed
  • Language for community and bot review is incorporated into the default community contributor message

AI use

Issue drafted & iteratively adjusted in collaboration with Claude. Final version carefully reviewed by @MisRob.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.