fix(github): fallback to public Orb slug when GITHUB_APP_SLUG is unset#5352
fix(github): fallback to public Orb slug when GITHUB_APP_SLUG is unset#5352JSONbored wants to merge 1 commit into
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review result - manual review recommendedReview updated: 2026-07-12 21:16:13 UTC
⏸️ Suggested Action - Manual Review Concerns raised — review before merging
📋 Copy for AI agents — paste into your coding agent
Review context
Contributor next steps
Signal definitions
[BETA] Chat with GittensoryAsk Gittensory a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://gittensory.aethereal.dev/docs/gittensory-commands 🟩 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.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5352 +/- ##
=======================================
Coverage 94.37% 94.37%
=======================================
Files 474 474
Lines 40128 40130 +2
Branches 14631 14632 +1
=======================================
+ Hits 37869 37871 +2
Misses 1583 1583
Partials 676 676
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
|
Closing as a regression, not a fix.
More importantly, this PR's fix inverts a deliberate design decision from #5269 (d56f4ec), which was already merged into It also only patches 1 of 5 byte-identical If we want the explicit fail-closed idiom applied consistently, the right shape is extending |
Motivation
env.GITHUB_APP_SLUGunguarded, which becomesundefined[bot]when the env var is removed and prevents dismissal of real Orb approvals, weakening branch-protection integrity.GITHUB_APP_SLUG.Description
PUBLIC_GITHUB_APP_SLUG = "gittensory-orb"constant and compute the effective bot login withenv.GITHUB_APP_SLUG?.trim() || PUBLIC_GITHUB_APP_SLUGinsidedismissLatestBotApprovalso dismissal still targets the real Orb bot when the env var is absent.dismissLatestBotApprovalimplementation to use the trimmed/ fallback slug before scanning reviews.test/unit/github-pr-actions.test.tsby allowing env overrides inenvWithKey(...)and adding regression tests that cover the unset and blankGITHUB_APP_SLUGbranches which assert thatgittensory-orb[bot]approvals are still dismissed.GITHUB_APP_SLUGis configured so self-host deployments continue to prefer their configured slug.Testing
npx vitest run test/unit/github-pr-actions.test.ts, and the file's tests passed (42 tests passed).npm run test:coverage, which exercised the test harness but failed global coverage thresholds and encountered long-running unrelated test suites in this environment, so the full unsharded coverage job did not report a green result.npm run typecheck, which failed due to pre-existing/unrelated typing issues in other packages and files and not due to the changes in this PR.Codex Task