Skip to content

Add support for Python type stub files (.pyi) #471

@Shashankss1205

Description

@Shashankss1205

Add support for Python type stub files (.pyi)

Description

Python .pyi files define public APIs and type contracts and are widely used in large Python codebases.
Indexing them improves API visibility and symbol resolution.

Extensions to add

  • .pyi

Implementation Notes

  • Parse only function/class signatures and type aliases
  • Skip runtime logic

How to Test

  1. Add a .pyi file in the sample_project:
    sample_pyi.pyi
  2. Run:
cgc start
cgc index sample_project
3. Verify:
React components and functions appear in the graph
Imports and exports are correctly linked
Attach a Screenshot of the code graph in your PR

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions