Skip to content

Conversation

@MuhammadUmer44
Copy link
Contributor

This PR adds Ruby LSP support to enable enhanced code analysis for Ruby projects:

  • Version flexibility: Works with any Ruby version via rbenv integration
  • Framework support: Auto-detects and supports Rails and RSpec projects
  • Performance: Enhanced code graph generation with more nodes and edges
  • Test coverage: Comprehensive tests for both LSP and non-LSP functionality
  • Cross-platform: Path normalization ensures tests pass on all operating systems
  • Robustness: Gracefully handles environments where LSP may not be available

The implementation makes the stakgraph tool more powerful for analyzing Ruby codebases while maintaining compatibility with various Ruby environments and project configurations.

Closed: #124

@MuhammadUmer44 MuhammadUmer44 force-pushed the feature/ruby-lsp-integration branch from b24b065 to 4cae6f2 Compare May 17, 2025 07:56
@MuhammadUmer44
Copy link
Contributor Author

@Evanfeenstra, please review this PR when you get a chance.

@fayekelmith
Copy link
Collaborator

Hello @MuhammadUmer44

I tested your PR locally and noticed a few issues.

  • When running your test for LSP, I altered the assertions, but the tests were still passing. Please, if you can structure your test as such: https://github.com/stakwork/stakgraph/blob/main/ast/src/testing/go/mod.rs. With improvements in testing the LSP counts for important Nodes and Edges.

  • Secondly, the changes in the client.rs file didn't affect the tests when I ran them. If, after updating the test, you can revert them and see if LSP still works, that would be nice.

  • Finally, please try using specific test : == not => or <= ; that way we can know when thinks break.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ruby LSP

2 participants