You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Handle host initialization in Initialize request delegate
This fixes a whole confusing mess of problems. Previously our initialize
delegate just set some options, but didn’t actually initialize the
host (which is required for the server to work). Instead, we relied on a
particular behavior of VS Code’s client to immediately send us an
`OnDidChangeConfiguration` request, where we then actually started the
host’s command loop. The logic was there because that’s where we
received the client’s configuration on loading profiles and initial
working directory. However, not all clients immediately sent this
request, resulting in PSES v3 not working in Vim or Emacs etc. This
behavior was also confusing! Instead, we now request that the client
send initialization configuration via the initialize request’s
parameters (in fact, the spec has an `initializationOptions` field just
for this). Based on these settings, we can now start the host at the
correct time. We also no longer respect `rootUri` as it has been
long-since deprecated. Note that we can “no longer” (but we weren’t
currently) respect a change to `EnableProfileLoading` nor
`InitialWorkingDirectory` after the server has initialized. But this
makes sense, you must restart it if you want to disable/enable profile
loading or change the initial working directory.
0 commit comments