Skip to content

feat(review): skip auto-review of docs-only PRs via review.auto_review.skip_docs_only - #3690

Merged
loopover-orb[bot] merged 1 commit into
JSONbored:mainfrom
bohdansolovie:feat/review-auto-review-skip-docs-only-2063
Jul 6, 2026
Merged

feat(review): skip auto-review of docs-only PRs via review.auto_review.skip_docs_only#3690
loopover-orb[bot] merged 1 commit into
JSONbored:mainfrom
bohdansolovie:feat/review-auto-review-skip-docs-only-2063

Conversation

@bohdansolovie

Copy link
Copy Markdown
Contributor

Summary

  • Add review.auto_review.skip_docs_only to the focus manifest so maintainers can skip AI auto-review when every changed file classifies as docs (classifyChangedFile === "docs").
  • Thread PR changed paths through resolveAutoReviewSkipForPullRequest / evaluateAutoReviewSkipReason, emitting review skipped (docs only) audit events. Empty file lists fail-safe to eligible.
  • Add unit, wiring, precedence-matrix, and queue integration tests for all-docs skip, mixed docs+source eligibility, empty list eligibility, and explicit off/null behavior.

Fixes #2063

Test plan

  • npx tsc -p tsconfig.json --noEmit
  • focus-manifest parse/evaluate/round-trip tests for skip_docs_only
  • auto-review-wiring tests for resolver + resolveAutoReviewSkipForPullRequest
  • auto-review-config-matrix precedence case for docs-only skip
  • queue.test.ts integration test for docs-only skip + audit detail

Made with Cursor

…w.skip_docs_only

Add a manifest knob that skips AI review when every changed file classifies
as docs, thread changed paths through the queue processor, and cover parse,
eligibility, wiring, and integration paths for codecov.

Co-authored-by: Cursor <cursoragent@cursor.com>
@bohdansolovie
bohdansolovie requested a review from JSONbored as a code owner July 6, 2026 04:12
@superagent-security

Copy link
Copy Markdown
Contributor

Superagent didn't find any vulnerabilities or security issues in this PR.

@loopover-orb loopover-orb Bot added the gittensor:bug Gittensor-scored bug fix — scores a 0.05x multiplier. label Jul 6, 2026
@loopover-orb

loopover-orb Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Warning

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

⏸️ Gittensory review result - manual review recommended

Review updated: 2026-07-06 04:19:02 UTC

7 files · 1 AI reviewer · no blockers · readiness 62/100 · CI green · clean

⏸️ Suggested Action - Manual Review

Review summary
This PR adds a `review.auto_review.skip_docs_only` focus-manifest flag that skips AI auto-review when every changed file classifies as "docs" via the existing `classifyChangedFile` helper, threading `changedPaths` through `evaluateAutoReviewSkipReason`/`resolvePullRequestAutoReviewSkipReason`/`resolveAutoReviewSkipForPullRequest` and into the queue processor. The empty-list fail-safe (empty changedPaths ⇒ not docs-only ⇒ eligible), parse/serialize round-trip, and precedence-matrix placement all look correct and are exercised by matching unit, wiring, and queue-integration tests. The one thing I can't verify from the diff alone is whether `getReviewFiles()` in `processors.ts` (now called unconditionally to build `autoReviewChangedPaths`) is memoized/already-fetched elsewhere in `maybePublishPrPublicSurface`, or whether this adds a redundant GitHub API fetch on every PR regardless of whether `skip_docs_only` is even configured.

Nits — 6 non-blocking
  • src/queue/processors.ts: confirm `getReviewFiles()` is cached/memoized within `maybePublishPrPublicSurface` — as written it's called unconditionally just to populate `autoReviewChangedPaths`, and if it isn't already memoized for the changed_files_summary/effort_score computation mentioned in the adjacent comment, this adds an extra fetch even when `skip_docs_only` is unset.
  • test/unit/queue.test.ts: the docs-only integration test stubs `/pulls/79/files` inline but relies on the same fetch mock also backing `getReviewFiles()` elsewhere in the flow — worth a comment noting that reuse so a future reader doesn't assume it's redundant.
  • src/signals/focus-manifest.ts:421: the doc comment cites issue `feat(review): skip auto-review of docs-only PRs via review.auto_review.skip_docs_only #2063` inline; consistent with the file's existing convention for other flags, so fine as-is, but worth keeping an eye on drift if the numbering scheme changes.
  • Consider adding a short code comment at the `getReviewFiles()` call site in processors.ts noting whether it's already-memoized, to make the reuse (or lack thereof) explicit for reviewers.
  • The precedence-matrix test in auto-review-config-matrix.test.ts is a good pattern for future auto_review flags — keep extending it as new skip predicates are added.
  • Readiness score is below the configured threshold — Use the readiness panel as advisory maintainer context; the score does not block this PR.
Signal Result Evidence
Code review ✅ No blockers 1 reviewer
Linked issue ✅ Linked #2063
Related work ⚠️ 3 scoped overlaps Top overlaps are listed below; lower-confidence bulk is hidden.
Change scope ❌ 8/20 High review scope from cached public metadata (1 linked issue).
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: 331 registered-repo PR(s), 195 merged, 8 issue(s).
Contributor context ✅ Confirmed Gittensor contributor bohdansolovie; Gittensor profile; 331 PR(s), 8 issue(s).
Gate result ✅ Passing No configured blocker found.
Review context
  • Author: bohdansolovie
  • Role context: outside_contributor
  • Public audience mode: oss maintainer
  • Lane context: Repository registration is not available in the local Gittensory cache.
  • Public profile languages: Python, C++, JavaScript
  • Official Gittensor activity: 331 PR(s), 8 issue(s).
  • Related work: Titles/paths share 7 meaningful terms. (issue #2051, issue #2046)
  • Related work: Titles/paths share 7 meaningful terms. (issue #2051, issue #2047)
  • Related work: Titles/paths share 7 meaningful terms. (issue #2051, issue #2048)
  • Additional title-only matches omitted; title-only overlap does not block.
Contributor next steps
  • Review top overlaps.
  • Add a concise scope and risk note.
  • Await review-lane availability.
  • Refresh registry data or choose a registered active repo.
  • Check active issues and PRs before submitting.
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

@loopover-orb loopover-orb Bot 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.

Gittensory approves — the gate is satisfied and CI is green.

@loopover-orb
loopover-orb Bot merged commit 525be40 into JSONbored:main Jul 6, 2026
6 checks passed
james3773 added a commit to james3773/gittensory that referenced this pull request Jul 6, 2026
Reconcile with the merged JSONbored#3690 base while keeping public-surface
eligibility, stored-file fallback, and isDocsOnlyChangedPaths wiring.

Co-authored-by: Cursor <cursoragent@cursor.com>
JSONbored added a commit that referenced this pull request Jul 6, 2026
…break ui:typecheck (#3709)

path-matchers.ts importing isCodeFile/isTestFile from local-branch.ts pulled
the whole review-scoring/Gittensor-API subsystem into any caller's import
graph. focus-manifest.ts (which PR #3690 made import classifyChangedFile
from path-matchers.ts) is reachable from the UI via a long-standing
cross-boundary import, so ui:typecheck started failing repo-wide with
Env/D1Database ambient-type errors it has no way to resolve.

Both functions were only ever thin, self-contained path-matching helpers
incidentally defined in local-branch.ts. Move them into path-matchers.ts
(zero remaining dependency on local-branch.ts), with local-branch.ts
importing them back and re-exporting for its existing importers. Add a
structural test asserting path-matchers.ts never imports from local-branch.ts
again.
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.

feat(review): skip auto-review of docs-only PRs via review.auto_review.skip_docs_only

1 participant