Do not reopen closed issues on new incoming email replies, add status/new-reply label instead

オープン 初心者向け
#90 コメント 3 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
85/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
java
領域
tooling

調査の方向性

まず MailProcessor.java を開き、クローズされた issue に対する受信メールの返信を処理するロジックを特定します。そのロジックを変更し、issue を再オープンしたり status/re-opened-by-bot ラベルを追加したりせず、コメントは引き続き追加しながら、代わりに status/triage ラベルを追加するようにします。関連するユニットテストを更新して、クローズされた issue がクローズ状態を維持し、新しい triage ラベルのみを受け取ることを確認します。その後、他に参照がなければ、未使用の Labels.REOPENED_BY_BOT 定数を削除します。

索引モデルが issue の本文から書いたものです。

説明

Summary

Following the discussion with @stianst, when new email replies arrive for an existing security issue (regardless of whether it is open or closed, in triage, waiting for a CVE, or closed/rejected), the bot should no longer reopen the issue or add the status/re-opened-by-bot label.

Instead, it should add the status/new-reply label. This label applies to both open and closed issues, but is only added when there is a new reply on an existing thread—never when a new issue is initially created.

When we respond to the email using commands like @security reply (or other respond/reject commands) or manually remove the label, the status/new-reply label should be removed.

Tracking of these issues will be managed via the GitHub Project (Keycloak Security Queue), configured with views filtered by label to identify issues with new replies needing follow-up, rather than relying on repository-level reopen state.


Proposed Changes
  1. Email Processing (MailProcessor.java):

    • When an email arrives for an existing issue (which can be either open or closed):
      • Do not call issue.reopen().
      • Do not add status/re-opened-by-bot (Labels.REOPENED_BY_BOT).
      • Add the status/new-reply label to indicate the reporter has sent a new reply.
      • Note: This label is only added on subsequent replies to existing issues, and never on initial issue creation (where we already know it requires response via source/email / status/triage).
      • Append the comment as usual.
  2. Command Processing:

    • When responding using @security reply (or respond/reject commands), the bot should automatically remove the status/new-reply label.
    • If a response is not needed, the label can be removed manually.
  3. GitHub Project View:

    • Use Keycloak Project #69 to track issues marked with status/new-reply that require attention and response.
  4. Cleanup:

    • Remove or deprecate unused Labels.REOPENED_BY_BOT constant and related label handling if no longer needed elsewhere.

Acceptance Criteria
  • Closed issues remain closed when new email comments are appended via MailProcessor.
  • status/new-reply label is attached to both open and closed issues when a new email reply arrives.
  • status/new-reply is not added to newly created issues upon initial creation.
  • status/re-opened-by-bot label is no longer added.
  • status/new-reply label is automatically removed when responding via @security reply (or equivalent commands).
  • Unit tests updated to verify closed state is preserved, initial creation does not get the label, and new-reply behavior on existing issues is correct.
主要言語
Java
スター
10
フォーク
11
平均マージ
9日 15時間
マージ済み PR(30日)
1

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

keycloak/keycloak-github-bot のほかの issue

keycloak/keycloak-github-bot の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。