Skip to content

Fix stale KBE action to use last summary table in issue body - #55195

Merged
MichaelSimons merged 1 commit into
mainfrom
michaelsimons-fix-stale-issue-last-summary-table
Jul 8, 2026
Merged

MichaelSimons merged 1 commit into
mainfrom
michaelsimons-fix-stale-issue-last-summary-table

Conversation

@MichaelSimons

Copy link
Copy Markdown
Member

When infrastructure updates Known Build Error issues, it appends or updates the last summary table in the issue body. When multiple tables exist, the stale action was reading the first (outdated) table, potentially marking issues as stale based on stale data. This has happened multiple times (e.g. #55174 is one such case).

This switches from .match() (returns first hit) to .matchAll() taking the last match, so the action always uses the most recent hit counts.

When infrastructure updates Known Build Error issues, it appends or
updates the last summary table in the body. When multiple tables exist,
the action was reading the first (stale) one. Switch from .match()
(first hit) to .matchAll() taking the last match so the action uses the
most recent hit counts.

Fixes issues like #55174 where 4 summary tables exist and only the
last one reflects current data.

Co-authored-by: Copilot App <[email protected]>

Copilot AI 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.

Pull request overview

Updates the KBE stale-management workflow to parse the most recent hit-count summary table from a Known Build Error issue body, avoiding decisions based on outdated tables when multiple summaries exist.

Changes:

  • Switch hit-count parsing from String.match() (first hit) to String.matchAll() and select the last match.
  • Add inline comments explaining why the last table is authoritative when multiple exist.

Comment thread .github/workflows/stale.yml Resolved
@MichaelSimons
MichaelSimons enabled auto-merge (squash) July 8, 2026 14:39
@MichaelSimons
MichaelSimons disabled auto-merge July 8, 2026 17:56
@MichaelSimons

Copy link
Copy Markdown
Member Author

Merging as the Build Analysis step appears hung. The dotnet-sdk-public-ci was green.

@MichaelSimons
MichaelSimons merged commit 07d53c0 into main Jul 8, 2026
32 of 33 checks passed
@MichaelSimons
MichaelSimons deleted the michaelsimons-fix-stale-issue-last-summary-table branch July 8, 2026 17:56
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jul 9, 2026
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.

3 participants