Multiple Local Targets for same LSP method? #813
-
In VS2022, I have a custom LSP using What I've come across is that Visual Studio is registering a local method for Will JsonRpc call multiple methods when they're mapped, or just the first? A further question may be whether Visual Studio is responding to the message and then 'doing something weird' to stop further handlers from being called? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
StreamJsonRpc will never dispatch a request to two methods. It will take the first match whose signature is compatible with the request. If you want to override or otherwise add your functionality to a method that already has a handler via the VS LSP library, you'll need to contact the VS LSP team to request that feature (assuming they don't already provide a means for that). |
Beta Was this translation helpful? Give feedback.
-
@CalvinAllen - can you clarify what you mean by removing your usage of all VS Language Client stuff and handling it all via JsonRpc "manually"? Are you hosting an LSP server? Or are you looking for a way to develop a generic extension that works across multiple IDE platforms? If so, which platforms are you targeting and what functionality are you looking to provide? |
Beta Was this translation helpful? Give feedback.
StreamJsonRpc will never dispatch a request to two methods. It will take the first match whose signature is compatible with the request. If you want to override or otherwise add your functionality to a method that already has a handler via the VS LSP library, you'll need to contact the VS LSP team to request that feature (assuming they don't already provide a means for that).