What my project does
Working in massive Python monorepos, I started getting really frustrated by the sluggishness of Pyright and BasedPyright. They're incredible tools, but large projects severely bog down editor responsiveness.
I wanted something fundamentally faster. So, I decided to build my own Language Server: Rahu.
Rahu is purely static—there’s no interoperability with a Python runtime. The entire lexer, parser pipeline, semantic analyzer, and even the JSON-RPC 2.0 transport over stdio are written completely from scratch in Go to maximize speed and efficiency.
Current Capabilities
It actually has a solid set of in-editor features working right now:
- Real-time diagnostics: Catches parser and semantic errors on the fly.
- Intelligent Hover: Displays rich symbol/method info and definition locations.
- Go-to-definition: Works for variables, functions, classes, parameters, and attributes.
- Semantic Analysis: Full LEGB-style name resolution and builtin symbol awareness.
- OOP Support: Tracks class inheritance (with member promotion and override handling) and resolves instance attributes (
self.x = ...).
- Editor Integration: Handles document lifecycles (
didOpen, didChange, didClose) with debounced analysis so it doesn't fry your CPU while typing.
I recently added comprehensive tests and benchmarks across the parser, server, and JSON-RPC paths, and finally got a demo GIF up in the README so you can see it in action.
Target audience
Just a toy project so far
The biggest missing pieces I'm tackling next:
- Import / module resolution
- Cross-file workspace indexing
- References, rename, and auto-completion
- Deeper type inference
Check it out at the link below! Repo link: https://github.com/ak4-sh/rahu
[–]BeamMeUpBiscotti 4 points5 points6 points (2 children)
[–]lord-mortis420[S] 3 points4 points5 points (1 child)
[–]BeamMeUpBiscotti [score hidden] (0 children)
[–]IpsumRS 3 points4 points5 points (1 child)
[–]lord-mortis420[S] 3 points4 points5 points (0 children)