File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed
Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -45,6 +45,9 @@ async def _notify_change_configuration(
4545 lsp_type .DidChangeConfigurationNotification (params = params )
4646 )
4747
48+ def get_default_settings (self ) -> Any :
49+ return {}
50+
4851 async def notify_change_configuration (self , settings : Any | None ) -> None :
4952 return await self ._notify_change_configuration (
5053 lsp_type .DidChangeConfigurationParams (settings = settings )
Original file line number Diff line number Diff line change 1818 build_server_request_hooks ,
1919)
2020from lsp_client .capability .notification import WithNotifyTextDocumentSynchronize
21+ from lsp_client .capability .notification .did_change_configuration import (
22+ WithNotifyDidChangeConfiguration ,
23+ )
2124from lsp_client .client .buffer import LSPFileBuffer
2225from lsp_client .jsonrpc .convert import (
2326 notification_serialize ,
@@ -300,6 +303,10 @@ async def __asynccontextmanager__(self) -> AsyncGenerator[Self]:
300303 )
301304 )
302305
306+ # send initial configuration if supported
307+ if isinstance (self , WithNotifyDidChangeConfiguration ):
308+ await self .notify_change_configuration (self .get_default_settings ())
309+
303310 try :
304311 yield self
305312 finally :
You can’t perform that action at this time.
0 commit comments