Problem
A same-stem sibling file of any language silently kills import-edge resolution for several languages: id disambiguation salts both file nodes (lead_py_lead, lead_ts_lead) while the import edge still targets the bare alias (lead), which now dangles. Everything downstream loses the edge — including Python's module-arm member-call resolution. A stray lead.md next to lead.rs is enough.
Measured affected (repros in upstream PR Graphify-Labs#2503, commits 4–5):
- Python (
import lead / module-arm calls)
- PowerShell, Zig, Rust, Pascal, Elixir (stem-named imports)
- bash — a different shape:
graphify/symbol_resolution.py re-derives ids by path formula after disambiguation, producing a duplicate dangling edge next to the correct one (and the same stale ids break its source-backed calls edges under collision)
Audited and NOT vulnerable: TS/JS (stamp target_file), C++/ObjC (header_remaps), Julia/Fortran/Verilog (importer-scoped target nodes), Dart (own stub nodes), Ruby/PHP (no file-targeting import edges).
Fix (reference implementation exists)
Upstream PR Graphify-Labs#2503 fixes this on upstream v8:
This issue tracks porting that work (2503 commits 4–5) to the fork's v8, adapted to the fork's diverged tree.
Open question inherited from the audit
Go's import edge dangles without any collision (go_pkg_example_com_m_lead unresolved with and without go.mod) — possibly a fixture problem, possibly a real Go resolution gap. Unasserted either way; needs its own investigation.
Acceptance criteria
Blocked by
None. Sibling: #24 (receiver-type index scoping — same porting pass, 2503 commits 2–3).
Problem
A same-stem sibling file of any language silently kills import-edge resolution for several languages: id disambiguation salts both file nodes (
lead_py_lead,lead_ts_lead) while the import edge still targets the bare alias (lead), which now dangles. Everything downstream loses the edge — including Python's module-arm member-call resolution. A straylead.mdnext tolead.rsis enough.Measured affected (repros in upstream PR Graphify-Labs#2503, commits 4–5):
import lead/ module-arm calls)graphify/symbol_resolution.pyre-derives ids by path formula after disambiguation, producing a duplicate dangling edge next to the correct one (and the same stale ids break its source-backedcallsedges under collision)Audited and NOT vulnerable: TS/JS (stamp
target_file), C++/ObjC (header_remaps), Julia/Fortran/Verilog (importer-scoped target nodes), Dart (own stub nodes), Ruby/PHP (no file-targeting import edges).Fix (reference implementation exists)
Upstream PR Graphify-Labs#2503 fixes this on upstream
v8:target_filehint the disambiguator already reads (the Phantom self-cycles: same-basename cross-extension re-exports (X.ts → ./X.mjs) collapse to one node Graphify-Labs/graphify#1814 mechanism) — an import in language X can only mean a language-X file, so the hint is unambiguous._hint_import_targets); it only picks among salted variants of an id the edge already named, so collision-free corpora are bit-identical.symbol_resolution.pyconsult post-disambiguation ids (_file_nids_by_path) so its duplicate dedupes away.This issue tracks porting that work (2503 commits 4–5) to the fork's
v8, adapted to the fork's diverged tree.Open question inherited from the audit
Go's import edge dangles without any collision (
go_pkg_example_com_m_leadunresolved with and withoutgo.mod) — possibly a fixture problem, possibly a real Go resolution gap. Unasserted either way; needs its own investigation.Acceptance criteria
extract()seam; red demonstrated against unfixed fork codetarget_filehint leaks intograph.jsoncec9cdd); counts reconciledBlocked by
None. Sibling: #24 (receiver-type index scoping — same porting pass, 2503 commits 2–3).