Skip to content

fix(review): skip additional binary extensions in full-file grounding#3404

Merged
gittensory-orb[bot] merged 2 commits into
JSONbored:mainfrom
jimcody1995:fix/review-grounding-binary-skip-ext-v2
Jul 5, 2026
Merged

fix(review): skip additional binary extensions in full-file grounding#3404
gittensory-orb[bot] merged 2 commits into
JSONbored:mainfrom
jimcody1995:fix/review-grounding-binary-skip-ext-v2

Conversation

@jimcody1995

Copy link
Copy Markdown
Contributor

Summary

Scope

Validation

  • git diff --check
  • npm run test:ci on Node 22
  • npm audit --audit-level=moderate — 0 vulnerabilities
  • Unit test asserts reads excludes all binary paths before fetch

Safety

  • No secrets, auth, or UI changes.
  • N/A for UI Evidence.

UI Evidence

N/A — backend review grounding only.

Notes

Conflict avoidance: Touches only src/review/review-grounding.ts and test/unit/review-grounding.test.ts. Zero overlap with open PRs (#3381 engine, #3380 enrichment, #3379 selfhost config-lint, #3378 dependency-scan tests, #3314 miner, #3373/#3304 focus-manifest, #3372/#3304 test-evidence, #3305 enrichment-wire, #3361 enrichment).

Made with Cursor

jimcody1995 and others added 2 commits July 5, 2026 07:50
avif/bmp/heic images and .tgz archives were not filtered by SKIP_EXT,
so full-file grounding wasted budget fetching unreadable blobs. Align
with common binary extensions from review/rag.ts BINARY_EXT_RE.

Co-authored-by: Cursor <cursoragent@cursor.com>
Record getFileContent calls and assert binary paths are never requested.

Co-authored-by: Cursor <cursoragent@cursor.com>
@jimcody1995 jimcody1995 requested a review from JSONbored as a code owner July 5, 2026 06:18
@superagent-security

Copy link
Copy Markdown

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

@gittensory-orb gittensory-orb Bot added the gittensor:bug Gittensor-scored bug fix — scores a 0.5x multiplier. label Jul 5, 2026
@gittensory-orb

gittensory-orb Bot commented Jul 5, 2026

Copy link
Copy Markdown

Warning

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

⏸️ Gittensory review result - manual review recommended

Review updated: 2026-07-05 06:23:37 UTC

2 files · 1 AI reviewer · no blockers · readiness 80/100 · CI green · clean

⏸️ Suggested Action - Manual Review

Review summary
This focused change extends the full-file grounding skip list for additional binary/archive extensions and updates the unit test to prove those paths are filtered before the fetcher is called. The production path in `fetchFullFileContents` filters candidates with `SKIP_EXT` before sorting and before `getFileContent`, and the new `reads` assertion exercises that real path rather than relying on sparse fetcher results. I do not see a reachable correctness defect in the visible diff.

Nits — 2 non-blocking
  • nit: `test/unit/review-grounding.test.ts:184` already proves the exact fetch list with `expect(reads).toEqual(["src/a.ts", "README.md"])`, so the subsequent per-binary `not.toContain` loop is useful documentation but logically redundant.
  • `test/unit/review-grounding.test.ts:168` could include an uppercase extension case such as `assets/photo.AVIF` to lock in the intended `/i` behavior for the expanded binary list.
Signal Result Evidence
Code review ✅ No blockers 1 reviewer
Linked issue ✅ Linked #3383
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 (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: 58 registered-repo PR(s), 31 merged, 0 issue(s).
Contributor context ✅ Confirmed Gittensor contributor jimcody1995; Gittensor profile; 58 PR(s), 0 issue(s).
Gate result ✅ Passing No configured blocker found.
Review context
  • Author: jimcody1995
  • 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: 58 PR(s), 0 issue(s).
  • PR-specific overlap: none found.
Contributor next steps
  • Await review-lane availability.
  • Refresh registry data or choose a registered active repo.
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

@codecov

codecov Bot commented Jul 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.46%. Comparing base (4fb8692) to head (c407833).
⚠️ Report is 13 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3404   +/-   ##
=======================================
  Coverage   93.46%   93.46%           
=======================================
  Files         287      287           
  Lines       30763    30763           
  Branches    11210    11210           
=======================================
  Hits        28752    28752           
  Misses       1355     1355           
  Partials      656      656           
Files with missing lines Coverage Δ
src/review/review-grounding.ts 92.85% <100.00%> (ø)
🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@gittensory-orb gittensory-orb Bot left a comment

Copy link
Copy Markdown

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.

@gittensory-orb gittensory-orb Bot merged commit 01844a4 into JSONbored:main Jul 5, 2026
8 checks passed
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.5x multiplier.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant