Repository navigation
Conversation
Refs Graphify-Labs#5613 Co-Authored-By: Codex <[email protected]>
|
Thanks for the pull request, @rvitaliy. A maintainer will review it soon. Want to talk it through while it is in review? Come join us on our Discord server. For longer-form discussion there is also GitHub Discussions. A couple of things that speed up review: make sure the test suite passes on Python 3.11 and 3.13, and that the change keeps extraction deterministic. |
There was a problem hiding this comment.
Graphify review 
5 possible issues to check · High impact
The change adds scoped TypeScript call resolution for const aliases of imported functions, including through runtime re-exports.
5 possible issues we couldn't confirm
- TypeScript callable scope entries now hold three values, so any reader that still unpacks two will fail on TypeScript files ·
graphify/extract.py:13182 - Import-alias calls are silently dropped for TypeScript files that have no owned callable bodies ·
graphify/extract.py:13184 - Local const aliases of undeclared globals are reported as imports ·
graphify/extractors/engine.py:8662 - +2 more in Graphify
They don't change the score.
What this review covered
- We didn't review 1 file that isn't source code, such as docs, config, images, or generated or third-party code.
- 5 of 5 changed files inspected. This is scope, not a correctness guarantee.
Code graph · 6388 functions depend on this change
- 5 functions became more coupled. Largest:
extract()(1429 callers),_apply_symbol_resolution_facts()(8 callers),_collect_js_symbol_resolution_facts()(5 callers). - 658 of 658 test files are affected by this change.
- Gate, test list and every flagged function: in the Graphify check.
Reviewed ef17d29 · 5 earlier findings not re-checked
Refs Graphify-Labs#5614 Co-Authored-By: Codex <[email protected]>
Extractor accuracy (Swift #5641, Apex #5627, Python #5647, TypeScript #5604/#5614/#5612, Bash caller-var #5602), GitHub Actions run-step extraction (#5603), incremental correctness (#5634/#5638/#5636), symlink and semantic-cache fixes (#5617/#5618), export/report hardening and perf (#5643/#5644/#5645/#5646/#5619/#5620/#5621), and CLI/docs/skill/install work (#5629/#5628/#5626/#5624/#5623/#5625/#5642/#5583). AST cache schema 59 to 60; Swift/Apex/Python/Bash/GHA inputs re-extract on first build. Co-Authored-By: Claude Opus 4.8 <[email protected]>
|
Landed in v0.9.124 (just released to PyPI), cherry-picked with your authorship preserved so it shows under your name in the history. Thanks @rvitaliy for resolving imported calls through scoped const aliases — verified green in the full suite and, where applicable, smoke-tested against the published package. 🙏 |
|
I'd like to take a follow-up on this: resolving calls through purely local function aliases ( |
What does this PR do?
Resolve an imported callable reached by a local
constalias inside an indexed TypeScript callable. The existing import and export facts must identify a single target. The edge keeps the lexical caller and the actual call line, including a call inside an anonymous callback.Closes #5613. Follow-up to #5594.
Type of change
Verification & Invariants
How was this tested?
v8with both full and incremental contexts. The focused extractor and architecture suites passed on Python 3.14 (223 tests), and the factory and typed receiver suites passed on Python 3.11 (41 tests).ruff check .,git diff --check, andgraphify update .passed. Pyright adds no diagnostics relative tov8.Graphify-specific checklist
Review follow-up
Use runtime module bindings to resolve scoped aliases. A local alias in an unrelated function and a type-only import cannot redirect the call. A same-named type and function keep the call when the indexed source location identifies the function declaration. The extractor's existing shared node ID can still hide the function when its same-named type comes first.
The updated branch passed 185 focused tests on Python 3.14 and six runtime-binding cases on Python 3.11. The full Python 3.14 suite passed with 12,474 tests. The installer and worker-sensitive tests ran without xdist after an intermittent installer fixture failed in the parallel run. The isolated installer test passed on both
v8and the updated branch. Ruff andgraphify update .passed, and Pyright adds no diagnostics relative tov8.