Skip to content

fix: clear stale maintainer labels on activity - #559

Open
akoumpa wants to merge 3 commits into
NVIDIA-NeMo:mainfrom
akoumpa:akoumpa/fix-event-driven-maintainer-label
Open

fix: clear stale maintainer labels on activity#559
akoumpa wants to merge 3 commits into
NVIDIA-NeMo:mainfrom
akoumpa:akoumpa/fix-event-driven-maintainer-label

Conversation

@akoumpa

@akoumpa akoumpa commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • clear waiting-on-maintainers immediately after qualifying human maintainer comments and PR review activity
  • classify the event actor independently from the issue/PR author while preserving existing community-request behavior
  • re-fetch the latest human-activity watermark immediately before a scheduled label add, suppressing stale writes when comments or reviews arrived after the project snapshot
  • include bodyless reviews in the race-detection watermark and ignore bot activity
  • check out the default branch for review-triggered workflows so fork content is never checked out alongside the App credentials

Motivation

The four-hour follow-up sweep can take several minutes between reading its project snapshot and mutating labels. On NVIDIA-NeMo/Automodel#3626, a maintainer /ok to test comment did not clear waiting-on-maintainers synchronously. Without a live recheck, a scheduled run can also add the label using pre-comment state.

The scheduled classifier remains the reconciliation path; this adds an immediate removal path and prevents stale scheduled additions.

Validation

  • python .github/actions/identify-follow-up-issues/test_identify_follow_up_issues.py (12 passed)
  • ruff check on the action and its tests
  • actionlint on both changed workflow files
  • bash -n on every embedded shell block in _community_bot.yml
  • live read-only freshness query against Automodel#3626 returned the expected human comment timestamp: 2026-08-24T16:14:08Z

Closes #558

Draft pending the issue approval required by this repository’s contribution policy.

Signed-off-by: Alexandros Koumparoulis <akoumparouli@nvidia.com>
@akoumpa
akoumpa marked this pull request as ready for review August 24, 2026 21:00

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

Changes requested.

Review notes

  • Maintainer activity must be separated from known service-account activity.
  • Scheduled freshness checks must ignore automated service-account comments.

Comment thread .github/workflows/_community_bot.yml Outdated
Signed-off-by: Alexandros Koumparoulis <akoumparouli@nvidia.com>

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

Changes requested.

Review notes

  • Review-triggered runs must reach label handling before maintainer activity can clear the label.
  • Protected App credentials must remain available without rejecting pull-request refs.

Comment thread .github/workflows/community-bot.yml
…hecks

Review events run on refs/pull/<number>/merge, which cannot satisfy a
deployment branch policy, so the reusable job is rejected before any step
runs on the 9 of 14 consumer repositories whose 'main' environment has one
(including this one). Route those events through a separate
review_environment input; all 14 already have an unprotected 'public'.

Also:
- derive the actor login from the same payload object as its type and
  association instead of github.actor
- share one service-account classifier between the author and actor paths
- skip the actor membership lookups on events that cannot clear the label
- warn when a membership lookup returns neither 204 nor 404
- collapse the per-inline-comment review event storm with a concurrency group
- keep the waiting-on-customer reconciliation when a stale add is suppressed
- suppress a stale add only when someone other than the snapshot's own author
  responded, so a requester chasing their own issue still gets the label
- replace the workflow substring assertions with a behavioural bash test and
  run the suite in CI
- drop a stray committed .pyc and add a .gitignore

Signed-off-by: Alexandros Koumparoulis <akoumparouli@nvidia.com>
@akoumpa
akoumpa force-pushed the akoumpa/fix-event-driven-maintainer-label branch from 99f1b8a to 995238c Compare August 25, 2026 23:35
@akoumpa
akoumpa requested a review from thomasdhc August 25, 2026 23:38
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.

Make waiting-on-maintainers removal event-driven and race-safe

2 participants