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

Abierto Apto para principiantes
#90 3 comentarios 1 reacción 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
85/100
Tipo de issue
Nueva funcionalidad
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
java
Área
tooling

Línea de trabajo

Empieza abriendo MailProcessor.java para localizar la lógica que gestiona las respuestas entrantes por correo electrónico para issues cerradas. Modifica esa lógica para que no vuelva a abrir la issue ni añada la etiqueta status/re-opened-by-bot, sino que añada la etiqueta status/triage y siga adjuntando el comentario. Actualiza las pruebas unitarias pertinentes para verificar que las issues cerradas permanezcan cerradas y solo reciban la nueva etiqueta de triage. Después, elimina la constante no utilizada Labels.REOPENED_BY_BOT si no tiene otras referencias.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

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.
Lenguaje dominante
Java
Estrellas
10
Forks
11
Merge medio
9 d 15 h
PR fusionados (30 d)
1

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de keycloak/keycloak-github-bot

Todos los issues de keycloak/keycloak-github-bot

Issues similares

Más issues de Java

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.