Thanks to visit codestin.com
Credit goes to github.com

Skip to content

ci(github): add stale-strings regression guard#933

Closed
itomek wants to merge 1 commit into
mainfrom
929-stale-strings-ci-guard
Closed

ci(github): add stale-strings regression guard#933
itomek wants to merge 1 commit into
mainfrom
929-stale-strings-ci-guard

Conversation

@itomek

@itomek itomek commented Apr 30, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds a GitHub Actions workflow that blocks retired UI terminology — RAUX, bare "GAIA UI", and Open-WebUI variants — from re-entering the repo via future PRs. Also fixes the last two stale checkbox labels in the old issue templates.

Why

Without a CI guard, the terminology cleaned up by PRs #930 and #931 can silently reappear through copy-paste from older branches or docs. The /reflect-plan adversarial review rated this the highest-ROI follow-up after the docs cleanup.

Refs #929

Changes

  • .github/workflows/stale-strings.yml — new workflow, runs on pull_request and push to main when .github/**, docs/**, CONTRIBUTING.md, or README.md change. Uses word-boundary regex (\bRAUX\b, \bGAIA UI\b, \bopen[-]?webui\b) to avoid false positives on "Gaia Agent UI". Excludes itself from the scan.
  • .github/ISSUE_TEMPLATE/bug_report.yaml — fixes the last remaining "GAIA UI (Open-WebUI)" checkbox label (superseded by the full template rewrite in #930 when that merges).
  • .github/ISSUE_TEMPLATE/feature_request.yaml — same as above.

Test plan

  • grep -rn -iE '\bRAUX\b|\bGAIA UI\b|\bopen[-]?webui\b' --exclude="stale-strings.yml" .github/ CONTRIBUTING.md docs/ README.md — zero hits on this branch
  • CI passes on this PR (the workflow runs on .github/** path changes)
  • After merging: open a test PR that adds "GAIA UI" to a doc file and confirm the workflow blocks it

Checklist

  • I have linked a GitHub issue above (Refs #929).
  • I have described why this change is being made, not just what changed.
  • No Python code changes — lint and unit tests are not applicable.
  • No user-visible behavior change — CI infrastructure only.

Adds a GitHub Actions workflow that prevents retired UI terminology
(RAUX, bare "GAIA UI", Open-WebUI) from re-entering the codebase.
The scan covers .github/, docs/, CONTRIBUTING.md, and README.md, and
uses word-boundary regex to avoid false positives on "Gaia Agent UI".

Also fixes the two remaining stale checkbox labels in the issue templates
that the workflow would otherwise block on its own CI run.

Refs #929
@itomek itomek requested a review from kovtcharov-amd as a code owner April 30, 2026 20:13
@github-actions github-actions Bot added the devops DevOps/infrastructure changes label Apr 30, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Summary

Small, well-scoped CI guard that prevents retired UI terminology (RAUX, bare GAIA UI, open-webui variants) from re-entering the docs/CI surface, plus two leftover label fixes in the legacy issue templates. The regex design is the load-bearing piece and it's correct: word-boundary anchors let Gaia Agent UI pass while flagging the bare GAIA UI form, and case-insensitivity catches all spellings of Open-WebUI. Verified locally with the same patterns against a representative input set.

Issues Found

🟢 Minor — actions/checkout@v4 is out of step with the rest of the repo (stale-strings.yml:18)

The repo overwhelmingly pins actions/checkout@v6 (~49 occurrences across workflows; only ~5 still on v4). Worth aligning so this doesn't become tomorrow's stale-version drift.

      - uses: actions/checkout@v6

🟢 Minor — Add a job-level timeout-minutes (stale-strings.yml:14)

GitHub's default job timeout is 360 minutes. A grep over .github/, docs/, CONTRIBUTING.md, and README.md should finish in seconds, so a small ceiling is cheap insurance against a wedged runner consuming the whole quota.

  stale-strings:
    name: Check for retired UI references
    runs-on: ubuntu-latest
    timeout-minutes: 5
    if: github.event_name != 'pull_request' || github.event.pull_request.draft == false || contains(github.event.pull_request.labels.*.name, 'ready_for_ci')

🟢 Minor — Failure message could point to the rule (stale-strings.yml:30)

When the check fires on someone else's PR a year from now, Use 'Gaia Agent UI' instead. is terse. Adding a one-line pointer to this workflow file (or to PR #929 / #930) makes the rule self-documenting and saves a maintainer round-trip.

            echo "Retired UI terminology found. Use 'Gaia Agent UI' instead."
            echo "See .github/workflows/stale-strings.yml for the rule (refs #929)."
            echo ""

🟢 Minor — 2>/dev/null || true masks real grep failures (stale-strings.yml:27)

The || true is needed because grep exits 1 when there are no matches, but bundling it with 2>/dev/null also silently swallows genuine errors (missing path, permission denied). Not a blocker — just worth knowing if the workflow ever appears to "pass" mysteriously while scanning nothing. Optional tightening: capture stderr separately, or check the exit code explicitly (if grep ... ; then ...). Discussion-only — no suggestion since either form is valid.

Strengths

  • Regex is genuinely careful. \bGAIA UI\b rules out the Gaia Agent UI substring without needing an explicit allow-list, and \bopen[-]?webui\b collapses the four common spellings into one pattern. Tested against the obvious false-positive cases and they all pass.
  • Self-exclusion via --exclude="stale-strings.yml" keeps the workflow's own comments (which deliberately spell out the banned strings) from triggering itself — a footgun that's easy to miss when authoring lint workflows.
  • Trigger surface is right-sized. paths: filters scope the run to the four directories the rule actually applies to; concurrency.cancel-in-progress: true and the ready_for_ci draft escape hatch match conventions used elsewhere in .github/workflows/.

Verdict

Approve with suggestions. No blocking issues. The four minor items above are polish — apply the checkout@v6 and timeout-minutes suggestions if you want a one-click cleanup before merge; the others are optional.

@itomek

itomek commented Apr 30, 2026

Copy link
Copy Markdown
Collaborator Author

Closing — regression guard adds CI complexity without sufficient value. The one-time cleanup is done.

@itomek itomek closed this Apr 30, 2026
@itomek itomek deleted the 929-stale-strings-ci-guard branch April 30, 2026 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

devops DevOps/infrastructure changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant