Summary
READS_FROM / WRITES_TO / FLOWS_TO are emitted for Python only. Every other indexed language parses into the graph with full structure/calls but produces zero I/O or data-flow edges, because the source/sink/handle registry and the processors' language gate are Python-specific.
Root cause (grounded)
- Both processors early-return for non-Python:
IOAccessProcessor.process_io_for_caller — if language != cs.SupportedLanguage.PYTHON: return (codebase_rag/parsers/io_access/processor.py:64).
FlowProcessor.process_flow_for_caller — same gate (codebase_rag/parsers/flow_access/processor.py:116).
- The registries have only Python entries:
IO_SINKS, IO_HANDLE_CONSTRUCTORS, IO_HANDLE_METHODS are keyed {SupportedLanguage.PYTHON: (...)} (codebase_rag/parsers/io_access/registry.py).
- The AST-node handling (assignment / call / return / handle-method detection, e.g.
_binding_from_node, _arg_names, _return_value_nodes) is written against Python tree-sitter node types (TS_PY_*).
Scope
Add per-language source/sink/handle tables plus per-language node-type handling. Rough per-language surface:
- Go —
os.Getenv/os.Open/os.Create, net/http (http.Get, http.Post), database/sql (db.Query, db.Exec), fmt.Println.
- JavaScript / TypeScript —
fs.readFile/writeFile, fetch/axios, process.env, console.log.
- Java —
java.io/java.nio streams, java.sql (Statement.execute*), System.getenv, System.out.print*.
- Rust —
std::fs, std::net, std::env::var, println!.
- C++ —
fstream, sockets, getenv, std::cout.
Each language also needs its own node-type constants for assignment/call/return and handle-method receiver parsing, mirroring the Python paths.
Suggested direction
- Generalize the registry maps to
{SupportedLanguage: (...)} (the dict shape already exists) and populate per language.
- Abstract the Python-specific node-type lookups behind a small per-language descriptor (assignment/left/right, call/function/arguments, return value nodes, attribute/handle receiver), so the processors' walk is language-agnostic.
- Land one language at a time behind the existing opt-in
io capture group, each with its own edge tests. Direction heuristics (e.g. the SQL first-keyword refinement) should be revisited per language.
Until then, non-Python I/O/flow is silently absent; this issue tracks closing that gap.
Summary
READS_FROM/WRITES_TO/FLOWS_TOare emitted for Python only. Every other indexed language parses into the graph with full structure/calls but produces zero I/O or data-flow edges, because the source/sink/handle registry and the processors' language gate are Python-specific.Root cause (grounded)
IOAccessProcessor.process_io_for_caller—if language != cs.SupportedLanguage.PYTHON: return(codebase_rag/parsers/io_access/processor.py:64).FlowProcessor.process_flow_for_caller— same gate (codebase_rag/parsers/flow_access/processor.py:116).IO_SINKS,IO_HANDLE_CONSTRUCTORS,IO_HANDLE_METHODSare keyed{SupportedLanguage.PYTHON: (...)}(codebase_rag/parsers/io_access/registry.py)._binding_from_node,_arg_names,_return_value_nodes) is written against Python tree-sitter node types (TS_PY_*).Scope
Add per-language source/sink/handle tables plus per-language node-type handling. Rough per-language surface:
os.Getenv/os.Open/os.Create,net/http(http.Get,http.Post),database/sql(db.Query,db.Exec),fmt.Println.fs.readFile/writeFile,fetch/axios,process.env,console.log.java.io/java.niostreams,java.sql(Statement.execute*),System.getenv,System.out.print*.std::fs,std::net,std::env::var,println!.fstream, sockets,getenv,std::cout.Each language also needs its own node-type constants for assignment/call/return and handle-method receiver parsing, mirroring the Python paths.
Suggested direction
{SupportedLanguage: (...)}(the dict shape already exists) and populate per language.iocapture group, each with its own edge tests. Direction heuristics (e.g. the SQL first-keyword refinement) should be revisited per language.Until then, non-Python I/O/flow is silently absent; this issue tracks closing that gap.