Repository navigation
Conversation
There was a problem hiding this comment.
Looks safe to merge — no coupling regressions and no blocking issues, checked against the code graph (not a self-assessment).
Graphify reviewed this change.
Looks safe to merge — no coupling regressions and no blocking issues, checked against the code graph (not a self-assessment).
Graphify review — findings
This PR modifies the _is_ignored logic in graphify/detect.py to handle the case where the scan root is a descendant of a .gitignore anchor directory. When the scan root differs from the pattern anchor, it rebases the relative path used for pattern matching to be relative to the scan root rather than the anchor. It also adds a new test verifying that nested files under a scan root aren't dropped when that root matches an ancestor's ignore rule (#2358), with the bulk of the diff being unrelated test-symbol churn in tests/test_detect.py.
No blocking issues surfaced. 4 lower-confidence candidates did not survive cross-model review.
Analysis details — impact, health, verification
Impact & health
Graphify review
Impact — 1168 functions depend on the 421 functions this change touches.
Health — this change adds coupling hotspots:
- worse:
detect()— 81 callers, 11 callees
Verification — 1168 functions in the blast radius were not formally verified this run (proofs are advisory here).
Gate & verification
graphify gate
PASS — objectively clean (no health regressions, tests not run — proofs not run this pass (advisory)). Grounded, not self-assessed.
Advisory (not blocking):
- verification_scope: 614 function(s) in the blast radius were not formally verified this run
· 1 more finding(s) on lines outside this diff (see the check run).
Fixes #2358
Problem
When the scan root itself is matched by an ancestor
.gitignore(e.g.
corpus/in the parent repo's.gitignore),detect()silently prunes all nested files while top-level files survive.
Fix
In
_eval(), when the scan root is a descendant of the pattern'sanchor directory, rebase the relative path to the scan root so
unanchored patterns only match path components below the scan
root — not the scan root's own name.
Testing
test_ancestor_gitignore_matching_scan_root_does_not_prune_nestedtest_detect.pysuite: 227 passed, 0 failed