Skip to content

ci(github): add stale issue workflow (dry-run) - #15027

Merged
DonLakeFlyer merged 1 commit into
mavlink:masterfrom
DonLakeFlyer:ci-stale-issues
Sep 3, 2026
Merged

ci(github): add stale issue workflow (dry-run)#15027
DonLakeFlyer merged 1 commit into
mavlink:masterfrom
DonLakeFlyer:ci-stale-issues

Conversation

@DonLakeFlyer

Copy link
Copy Markdown
Contributor

Summary

Adds a nightly actions/stale workflow to work down the open issue backlog (~976 open, ~630 untouched for over a year, ~540 filed more than 5 years ago). Modeled on PX4-Autopilot's stale.yml.

Behavior

  • Issues with no activity for 90 days get the stale label (silently — no comment, to avoid a notification flood on the initial sweep).
  • Issues still inactive 30 days after being labeled are closed with a canned message.
  • Any comment or edit removes the stale label.
  • Two jobs so the close message fits the issue type:
    • Non-feature issues — asks the reporter to retest on the latest Stable/Daily and reopen or file a new issue with version/firmware/platform/repro.
    • Feature Request — asks to reopen or start a Discussion if there is still interest.
  • Exempt: any issue with a milestone, Priority: Critical.
  • Pull requests are not touched.
  • operations-per-run: 400 per job keeps both jobs under the GITHUB_TOKEN 1000 req/hr cap; the initial sweep spreads over a few nights.

Rollout

This PR ships with debug-only: true, so the workflow only logs what it would label/close. Plan:

  1. Merge, trigger via workflow_dispatch, review the log to confirm counts and that exemptions are honored.
  2. Follow-up PR removes debug-only to go live. First nightly run labels; closes begin 30 days later.

Note: 68 open issues already carry a manually applied stale label. Once live, those that have not been updated since labeling will be closed on the first run (no additional grace period).

Copilot AI balanced review requested due to automatic review settings September 2, 2026 21:21
@github-actions github-actions Bot added github_actions Pull requests that update GitHub Actions code size/XS labels Sep 2, 2026

steps:
- name: Harden Runner
uses: step-security/harden-runner@v2

steps:
- name: Harden Runner
uses: step-security/harden-runner@v2
@github-actions

github-actions Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

⚠️ Build results unavailable — artifact download from one or more platform workflows failed
(likely artifact retention expiry or transient API error). The combined report cannot be generated for this run.

See the Build Results workflow run for details.

This comment was marked as resolved.

Nightly actions/stale run that labels issues untouched for 90 days as
stale and closes them 30 days later. Feature requests are processed in a
separate job so they get their own close message. Milestoned issues and
Priority: Critical are exempt; pull requests are not touched.

Ships with debug-only enabled so the first runs only log what would be
labeled/closed. A follow-up removes debug-only once the dry-run output
has been reviewed.

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.

🟡 Changes recommended

The dry-run workflow unnecessarily retains write permissions that should be restricted before approval.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Review details

Suppressed comments (1)

.github/workflows/stale.yml:63

  • The feature-request dry run also grants unnecessary write access to issues and Actions caches. Restrict this job to read access now, then elevate it in the follow-up that removes debug-only.
    permissions:
      issues: write
      actions: write
  • Files reviewed: 2/2 changed files
  • Comments generated: 2
  • Review effort level: Balanced

Comment on lines +19 to +22
permissions:
issues: write
# Required to reset the Actions cache entry that persists resume state between capped runs.
actions: write
Comment thread .github/ci-overview.md
| `crowdin.yml`, `lupdate.yml` | Translation workflows |
| `dependency-review.yml` | Dependency security review |
| `scorecard.yml` | OpenSSF Scorecard |
| `stale.yml` | Nightly stale-issue labeling and closing (feature requests get their own close message) |
@DonLakeFlyer
DonLakeFlyer merged commit f14c6d6 into mavlink:master Sep 3, 2026
34 checks passed
@DonLakeFlyer
DonLakeFlyer deleted the ci-stale-issues branch September 3, 2026 15:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Pull requests that update GitHub Actions code size/XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants