Skip to content

test(ci): sync workflow-runner-labels with the github-hosted runner migration - #2831

Closed
ultrahighsuper wants to merge 1 commit into
JSONbored:mainfrom
ultrahighsuper:fix/sync-workflow-runner-labels-test
Closed

test(ci): sync workflow-runner-labels with the github-hosted runner migration#2831
ultrahighsuper wants to merge 1 commit into
JSONbored:mainfrom
ultrahighsuper:fix/sync-workflow-runner-labels-test

Conversation

@ultrahighsuper

Copy link
Copy Markdown
Contributor

Problem: main is red

#2825 ("ci(runners): use github-hosted validation") moved every CI/audit job off the self-hosted gittensory pool onto GitHub-hosted ubuntu-latest runners, but did not update test/unit/workflow-runner-labels.test.ts, which still asserts the removed self-hosted configuration. The suite now fails on main:

Both fail on every PR's validate-code, so the gate's required check is red repo-wide.

Fix (test-only)

Sync the assertions with #2825's github-hosted policy, keeping the test meaningful (it still fails if the self-hosted pool ever returns):

  • ci.yml: no job's runs-on may target the self-hosted/gittensory pool — in either the YAML [self-hosted, gittensory] array or the JSON "self-hosted" fork-aware expression (a self-hosted mention may still legitimately survive in a comment or a gittensory-* path glob, so the assertions match the runs-on forms, not the whole file). Every job — changes, validate-code, security, validate — is asserted runs-on: ubuntu-latest. The structural guards are unchanged (single validate-code build/test job, gate needs: [changes, validate-code, security], no fanned-out per-language jobs).
  • audit.yml: asserts runs-on: ubuntu-latest and no self-hosted runs-on.

Also normalizes CRLF→LF in the file reader so the \n-anchored job slices are stable regardless of checkout line endings.

No workflow files are touched — this only makes the test reflect the already-merged, intentional runner migration. Verified the full workflow-runner-labels suite (3 tests) passes and tsc --noEmit is clean.

No linked issue: issue creation is unavailable for this account.

…igration

JSONbored#2825 moved every CI/audit job off the self-hosted gittensory pool onto
GitHub-hosted ubuntu-latest runners but left workflow-runner-labels.test.ts
asserting the removed self-hosted runs-on — so the suite fails on main
(the ci.yml trusted-pool expression is gone, and audit.yml is no longer
self-hosted). Update the assertions to the github-hosted policy: no job
runs-on may target the self-hosted/gittensory pool, and every job runs on
ubuntu-latest. Also normalize CRLF so the job slices are stable on either
line-ending checkout.
@ultrahighsuper
ultrahighsuper requested a review from JSONbored as a code owner July 3, 2026 21:15
@loopover-orb loopover-orb Bot added the gittensor:bug Gittensor-scored bug fix — scores a 0.05x multiplier. label Jul 3, 2026
@loopover-orb

loopover-orb Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Warning

🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨

⏸️ Gittensory review result - manual review recommended

Review updated: 2026-07-03 21:13:56 UTC

1 file · 1 AI reviewer · no blockers · readiness 80/100 · CI green · dirty

⏸️ Suggested Action - Manual Review

Review summary
The change correctly updates the workflow drift tests to match the GitHub-hosted runner migration and removes the obsolete self-hosted expression helper. The CI workflow test now covers all expected jobs and preserves the existing structural guards, and the CRLF normalization is a reasonable stabilizer for the string-slice assertions. The only notable weakness is that the audit workflow guard is narrower than the CI guard, so it would miss some self-hosted `runs-on` expression forms if audit.yml grows another job.

Nits — 5 non-blocking
  • nit: test/unit/workflow-runner-labels.test.ts:46 should mirror the CI self-hosted guards for audit.yml, because the current audit test only rejects the YAML array form and would not catch a JSON/fromJSON self-hosted runner expression.
  • nit: test/unit/workflow-runner-labels.test.ts:35 could assert the job boundary indexes are present before slicing, because `indexOf(...) === -1` makes a missing or reordered job produce a misleading slice rather than a clear failure.
  • In test/unit/workflow-runner-labels.test.ts:46, add the same `not.toContain('"self-hosted"')`, `not.toContain("|| 'self-hosted'")`, and `not.toContain('"fork-ci"')` checks used for ci.yml unless audit.yml intentionally allows those forms.
  • In test/unit/workflow-runner-labels.test.ts:35, make `jobSlice` fail explicitly when either boundary is missing before calling `slice`.
  • In test/unit/workflow-runner-labels.test.ts:15, consider tightening the comment or the assertion so they match: `not.toContain('"self-hosted"')` scans the whole file, not just `runs-on` forms.
Signal Result Evidence
Code review ✅ No blockers 1 reviewer
Linked issue ✅ No-issue rationale PR body explains why no issue is linked.
Related work ✅ No active overlap found No same-issue or scoped active PR overlap found.
Change scope ✅ 20/20 Low review scope from cached public metadata (no linked issue context).
Validation posture ❌ 5/25 Preflight is holding this PR: the review lane is unavailable, so it is not ready for automated review.
Contributor workload ✅ 10/10 Author activity: 69 registered-repo PR(s), 46 merged, 9 issue(s).
Contributor context ✅ Confirmed Gittensor contributor ultrahighsuper; Gittensor profile; 69 PR(s), 9 issue(s).
Gate result ✅ Passing No configured blocker found.
Review context
  • Author: ultrahighsuper
  • Role context: outside_contributor
  • Public audience mode: oss maintainer
  • Lane context: Repository registration is not available in the local Gittensory cache.
  • Public profile languages: not available
  • Official Gittensor activity: 69 PR(s), 9 issue(s).
  • PR-specific overlap: none found.
Contributor next steps
  • Await review-lane availability.
  • Refresh registry data or choose a registered active repo.
  • Link the issue being solved, or explicitly explain why this is a no-issue PR.
Signal definitions
  • Related work = same linked issue, overlapping active PRs, or title/path similarity.
  • Change scope = cached public metadata such as size labels, draft state, and review-burden hints.
  • Validation posture = whether the PR provides enough public validation/test evidence for maintainer review.
  • Contributor workload = public contributor activity and cleanup pressure, not a repo-wide quality failure.
  • Contributor context = public GitHub/Gittensor identity context; non-Gittensor status is not a blocker.

🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed


💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →.

Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.

  • Re-run Gittensory review

@ultrahighsuper

Copy link
Copy Markdown
Contributor Author

Superseded by #2827, which made the same workflow-runner-labels update for the #2825 github-hosted runner migration and is already merged. Closing as redundant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gittensor:bug Gittensor-scored bug fix — scores a 0.05x multiplier.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant