facebook / starlark-rust

A Rust implementation of the Starlark language
Apache License 2.0
699 stars 57 forks source link

symbols in prelude files (passed in via --prelude) don't autocomplete in lsp mode #114

Open chancila opened 7 months ago

chancila commented 7 months ago

Is it expected that symbols in the prelude autocomplete when using the vscode extension + the plain starlark binary in LSP mode?

I've tweaked the the VS code LSP args to pass --prelude in, and doing cargo run -- some_test_file.star --prelude prelude.star causes a successful evaluation, however the LSP server does not seem to have any symbols in the prelude in completion requests in VS code

ndmitchell commented 1 month ago

I don't think anyone considered it too carefully. Generally most people will need to build their own LSP to deal with their own Rust builtins. I think we'd probably accept a patch to make that work, but think of the unmodified LSP as mostly for demo purposes. Generally you build a specific one for your project and ship that.