Skip to content

[Bug]: TypeScript calls to properties typed via indexed access are missing #5599

Done

Description

@rvitaliy

Pre-flight checks

  • I have checked the Troubleshooting section in the README and searched existing issues.

What happened?

Graphify skips a TypeScript property declared as dispatch: Store['run'] even when Store.run has a method signature in the same file. As a result, a call through a parameter typed as Api has no calls edge to the declared Api.dispatch property.

I expected Graphify to include dispatch as a callable member of Api and link the call to that declaration. The indexed access supplies the signature. It does not establish which concrete implementation runs.

Steps to reproduce

In an empty directory:

cat > ports.ts <<'TS'
interface Store { run(): number }
export interface Api { dispatch: Store['run'] }
TS

cat > caller.ts <<'TS'
import type { Api } from './ports';
export const call = (api: Api) => api.dispatch();
TS

graphify extract . --no-cluster --code-only

python3 - <<'PY'
import json
from pathlib import Path

graph = json.loads(Path('graphify-out/graph.json').read_text())
nodes = {node['id']: node for node in graph['nodes']}
print([
    (nodes[edge['source']]['label'], nodes[edge['target']]['label'],
     nodes[edge['target']]['source_file'], edge['confidence'])
    for edge in graph['edges'] if edge['relation'] == 'calls'
])
PY

Graph output

Actual calls: [].

Expected: an INFERRED edge from call() in caller.ts to .dispatch() on Api in ports.ts.

Environment

  • Graphify 0.9.122, reproduced from a clean copy of v8 at a7295bca.
  • macOS arm64, CPython 3.14.10, source checkout with uv.
  • Code-only extraction on a fresh directory with no existing graph.

Related work

#5586 follows typed property receivers such as deps.port.inspect(). This case is about the callable member declaration itself and reproduces with a direct api.dispatch() call.

Activity

  1. github-actions commented on Nov 28, 2026

    @github-actions

    Thanks for opening this issue, @rvitaliy. A maintainer will take a look soon.

    If you would like to discuss it in real time, come say hi on our Discord server. For longer-form questions and ideas there is also GitHub Discussions.

    To help us triage, please make sure the report includes what you expected, what actually happened, and the steps (and a small sample) to reproduce it.

  2. added a commit that references this issue on Nov 30, 2026
    a15de94
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions