Skip to content

fix(detect): prune only configured output path - #2335

Open
oleksii-tumanov wants to merge 1 commit into
Graphify-Labs:v8from
oleksii-tumanov:fix/graphify-out-path-exclusion
Open

fix(detect): prune only configured output path#2335
oleksii-tumanov wants to merge 1 commit into
Graphify-Labs:v8from
oleksii-tumanov:fix/graphify-out-path-exclusion

Conversation

@oleksii-tumanov

Copy link
Copy Markdown
Contributor

Summary

  • Stop treating the basename of a nested GRAPHIFY_OUT as a global directory-name exclusion.
  • Prune only the configured output directory by resolved path, including in-repository symlink aliases.
  • Cover default-parent, custom-parent, absolute, and symlinked nested output paths.

Fixes #2273

Testing

  • uv run --frozen pytest tests/test_detect.py tests/test_paths.py -q --tb=short — 265 passed
  • uv run --frozen pytest tests/ -q --tb=short — 3902 passed, 3 skipped; the one local failure in test_merge_graphs_preserves_import_edge_direction reproduces unchanged on pristine v8 at 4fe1109
  • uv run --frozen python -m tools.skillgen --check — 134 artifacts match

@graphify-labs graphify-labs 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.

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 changes how the detect scan identifies and prunes the configured Graphify output directory. Instead of adding the output directory's basename to the static _SKIP_DIRS set (which pruned any directory matching that name), it now resolves the specific configured output path at scan time and prunes only directories that resolve to that exact path. Related exports/comments in paths.py were updated to reflect that GRAPHIFY_OUT_NAME is no longer used for scan exclusion. The surface area includes detect() in graphify/detect.py, the _SKIP_DIRS set, comment/docstring updates in graphify/paths.py, and a new parametrized test in tests/test_detect.py covering nested, custom, absolute, and symlinked output paths.

No blocking issues surfaced. 4 lower-confidence candidates did not survive cross-model review.

Analysis details — impact, health, verification

Impact & health

Graphify review

Impact — 1340 functions depend on the 444 functions this change touches.

Health — grade A; 10 existing hotspot(s) in the area this change touches (pre-existing, not introduced here):

  • extract() — 351 callers, 28 callees (high)
  • _rebuild_code() — 55 callers, 48 callees (high)
  • detect() — 80 callers, 11 callees (high)
  • extract_files_direct() — 15 callers, 19 callees (high)
  • extract_xaml() — 19 callers, 12 callees (high)
  • dispatch_command() — 2 callers, 110 callees (high)
  • to_json() — 34 callers, 6 callees (high)
  • write_callflow_html() — 7 callers, 24 callees (high)
  • …and 2 more

Verification — 1340 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: 972 function(s) in the blast radius were not formally verified this run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GRAPHIFY_OUT nested path excludes every directory matching its basename from the scan (detect.py GRAPHIFY_OUT_NAME)

1 participant