fleet/.github
Copilot b7440e8d7f
Add automated workflow for tagging aging bugs (#39284)
Automates bug triage by tagging issues based on age: `~old bug` for bugs
≥180 days, `~aging bug` for bugs ≥90 days.

Relates to #39155.

## Changes

**New workflow: `.github/workflows/tag-aging-bugs.yml`**
- Runs daily at 8:06 UTC via cron, supports manual dispatch
- Dry run mode (default: false) logs actions without modifying labels
- Two-pass processing:
  1. Bugs ≥180 days: adds `~old bug`, removes `~aging bug` if present
  2. Bugs ≥90 days without either label: adds `~aging bug`
- Uses github-script with pagination for scalability
- Follows repo patterns (harden-runner, proper permissions)

# Checklist for submitter

- [x] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)

## Testing

- [x] QA'd all new/changed functionality manually

<!-- START COPILOT CODING AGENT SUFFIX -->



<!-- START COPILOT ORIGINAL PROMPT -->



<details>

<summary>Original prompt</summary>

> Add a GitHub Actions workflow that runs daily at 8:06am UTC, and can
be manually dispatched. In that workflow, retrieve all issues labelled
`bug` created >= 180 days ago that don't include the `~old bug` tag,
then for each bug add the `~old bug` tag and remove `~aging bug` if it
is applied. Then retrieve all issues labelled `bug` created >= 90 days
ago that has neither `~aging bug` nor `~old bug` tags, and add the
`~aging bug` tag. Include a dry run workflow parameter, default off,
that logs rather than setting the label.


</details>



<!-- START COPILOT CODING AGENT TIPS -->
---

💬 We'd love your input! Share your thoughts on Copilot coding agent in
our [2 minute survey](https://gh.io/copilot-coding-agent-survey).

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: iansltx <472804+iansltx@users.noreply.github.com>
2026-02-03 18:00:58 -06:00
..
actions Added fleet-gitops to eng metrics. (#36706) 2025-12-08 16:27:06 -06:00
ISSUE_TEMPLATE Create "quick win" issue template and update handbook (#39081) 2026-02-03 13:06:51 -06:00
scripts Standardize macOS app update queries and related automation (#39164) 2026-02-03 17:52:07 -06:00
workflows Add automated workflow for tagging aging bugs (#39284) 2026-02-03 18:00:58 -06:00
dependabot.yml Remove daily schedule so it only gets triggered by security alerts (#14871) 2023-11-02 09:53:40 -05:00
pull_request_template.md Remove unclear item from pull_request_template (#34029) 2025-10-09 17:38:41 -03:00