Skip to content

fix(review): rank all path-matchers lockfiles in diffFilePriority#3371

Merged
gittensory-orb[bot] merged 1 commit into
JSONbored:mainfrom
jimcody1995:fix/review-diff-lockfile-parity
Jul 5, 2026
Merged

fix(review): rank all path-matchers lockfiles in diffFilePriority#3371
gittensory-orb[bot] merged 1 commit into
JSONbored:mainfrom
jimcody1995:fix/review-diff-lockfile-parity

Conversation

@jimcody1995

Copy link
Copy Markdown
Contributor

Summary

  • Extend diffFilePriority in review-grounding.ts and review-diff.ts to recognize every lockfile basename from path-matchers.ts LOCKFILE_NAMES (e.g. bun.lock, uv.lock, deno.lock, flake.lock, mix.lock, chart.lock).
  • Previously only a subset (npm/yarn/pnpm/cargo/poetry/composer/go.sum/bun.lockb) ranked as noise 4; other lockfiles ranked as source 0 and could displace real code under a tight diff budget.

Scope

  • Conventional Commit title format.
  • Focused — review diff priority + unit tests only.
  • Follows CONTRIBUTING.md.
  • No linked issue needed.

Validation

  • git diff --check
  • npm run test:ci on Node 22
  • npm audit --audit-level=moderate — 0 vulnerabilities
  • Unit tests cover representative new lockfile basenames

Safety

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

UI Evidence

N/A — backend review diff ordering only.

Notes

Conflict avoidance: Touches only src/review/review-grounding.ts, src/review/review-diff.ts, and their unit tests. Zero overlap with open PRs (#3368 engine, #3367/#3304 queue, #3366 agent-action-executor, #3361 enrichment, #3314 miner, #3305 enrichment-wire). Merges cleanly after any of those land without rebase.

Made with Cursor

bun.lock, uv.lock, deno.lock, and other ecosystem lockfiles were
treated as source(0) under a tight diff budget, displacing real code.
Align review-grounding and review-diff with path-matchers lockfiles.

Co-authored-by: Cursor <cursoragent@cursor.com>
@jimcody1995 jimcody1995 requested a review from JSONbored as a code owner July 5, 2026 05:19
@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 05:24:17 UTC

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

⏸️ Suggested Action - Manual Review

Review summary
The change extends both diff priority copies so the newly listed lockfile basenames rank as noise(4), preserving source-first ordering under tight budgets. The basename-anchored regex remains consistent between review-diff and review-grounding, and the provided CI shows the changed paths are already verified. I do not see a reachable correctness break in the visible diff, but the fix still duplicates canonical lockfile knowledge and the new tests only sample the expanded list.

Nits — 4 non-blocking
  • nit: test/unit/review-diff.test.ts:21 and test/unit/review-grounding.test.ts:105 say "every path-matchers lockfile" but only cover six representative names, so rename the case or iterate the canonical LOCKFILE_NAMES list if that export is available.
  • nit: src/review/review-diff.ts:23 and src/review/review-grounding.ts:113 now carry the same long lockfile regex literal, which preserves current behavior but makes the next path-matchers update easy to miss.
  • src/review/review-diff.ts:23 and src/review/review-grounding.ts:113: change this to consume the shared path-matchers lockfile source, or add a small shared helper that both priority functions use, so there is one list to update.
  • test/unit/review-diff.test.ts:21 and test/unit/review-grounding.test.ts:105: either rename the test to "ranks representative path-matchers lockfiles" or assert the full canonical list, including existing entries like npm-shrinkwrap.json, go.work.sum, packages.lock.json, and gradle.lockfile.
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: 46 registered-repo PR(s), 23 merged, 0 issue(s).
Contributor context ✅ Confirmed Gittensor contributor jimcody1995; Gittensor profile; 46 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: 46 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.
  • 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

@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.88%. Comparing base (f8c86e6) to head (195cc84).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3371   +/-   ##
=======================================
  Coverage   93.88%   93.88%           
=======================================
  Files         283      283           
  Lines       30572    30572           
  Branches    11137    11137           
=======================================
  Hits        28704    28704           
  Misses       1211     1211           
  Partials      657      657           
Files with missing lines Coverage Δ
src/review/review-diff.ts 90.90% <100.00%> (ø)
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 07401e2 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