fix(review): refresh PR files when pre-merge checks are path-gated#1402
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1402 +/- ##
=======================================
Coverage 95.38% 95.39%
=======================================
Files 201 201
Lines 21598 21601 +3
Branches 7807 7807
=======================================
+ Hits 20601 20606 +5
+ Misses 416 415 -1
+ Partials 581 580 -1
🚀 New features to boost your workflow:
|
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
gittensory-ui | 81f1b63 | Commit Preview URL Branch Preview URL |
Jun 26 2026, 07:05 AM |
81f1b63 to
e3fe950
Compare
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review — held for maintainer review
⏸️ Held for maintainer review
Nits — 2 non-blocking
Review context
Contributor next steps
Signal definitions
🟩 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.
|
Motivation
review.pre_merge_checks(entries withwhen_paths) rely on accurate PR file lists to decide whether an enforced check applies, and stale cachedpull_request_filescould let an enforced check be incorrectly ignored.Description
shouldRefreshFilesForPreMergeChecks(env, repoFullName)to detect whether the repo manifest contains anypre_merge_checkswithwhen_paths.refreshPullRequestDetailsruns when path-gated checks are configured.test/unit/gate-check-policy.test.tsand a synchronize regression test that seeds stale cached files and verifies a live files fetch replaces them intest/unit/queue.test.ts.Testing
git diff --checkandnpm run typecheck, both succeeded.npx vitest run test/unit/gate-check-policy.test.ts test/unit/queue.test.ts -t "refreshes files when pre-merge checks|refreshes pull request files for path-gated pre-merge checks"and the new/affected tests passed.npm run test:ci; the run progressed but could not be completed in this environment (coverage phase / long-running CI step was stopped).npm audit --audit-level=moderatecould not complete due to the registry audit endpoint returning403 Forbiddenin this environment.Codex Task