Skip to content

assorted fixes(LSP, AI, etc) - #3065

Merged
abose merged 7 commits into
mainfrom
lspFix
Aug 3, 2026
Merged

assorted fixes(LSP, AI, etc)#3065
abose merged 7 commits into
mainfrom
lspFix

Conversation

@abose

@abose abose commented Aug 2, 2026

Copy link
Copy Markdown
Member

see individual commit descitpions

abose added 4 commits August 2, 2026 18:46
- Normalize the drive letter of server-returned file:// URIs to
  uppercase on Windows in serverUriToVfsUri. Servers like tsserver
  lowercase the drive letter, which mapped the same file to a second
  case-sensitive VFS path, so jump-to-definition opened a duplicate
  document. Single choke point covers definitions, references and
  diagnostics for all registered LSP servers.

- An intentional restartLanguageServer stop could be misread as a
  crash: the stopped process exit event lands after _stopping is
  reset, bumping _crashCount and scheduling an auto-restart that
  races the restart already in flight (two concurrent starts orphan
  one initialize request, which then times out after 120s). Guard
  with a _restarting flag held across the whole stop+start, plus a
  pid generation check (node side now reports the exiting process
  pid in serverExit) to ignore stale exits of replaced processes.
filterText is called directly by JavaScriptRefactoring highlight
references on cursorActivity, which can run before any Tern init or
projectOpen has populated preferences, throwing a null getMaxFileSize
TypeError on every cursor move over a JS identifier.
The SDK now surfaces auth failures as 'Claude Code returned an error
result: Failed to authenticate. API Error: 401 OAuth access token has
expired...' which the isAuthError regex missed ('oauth token' does not
match 'OAuth access token'), so the panel showed a raw error instead of
the login-in-terminal action. Match \b401\b (phrasing-proof), plus
'oauth[\w ]*token' and 're-?authenticate'. 403 stays excluded — it
means forbidden, not re-login.
@abose abose changed the title Lsp fix assorted fixes(LSP, AI, etc) Aug 2, 2026
abose added 3 commits August 2, 2026 19:08
Before the SDK's supportedModels() list arrives (first ever chat), the
model dropdown fell back to a bare list with no Fable entry and no
descriptions. Add localized description strings for the static fallback,
including an access caveat for Fable and a generic Default subtext shown
until the resolved default model is known.
…ed processes

During a fast restart the old process's exit event can land after the
replacement server was already registered. The exit/error handlers
deleted the registry entry unconditionally, removing the NEW server's
entry - its initialize response was then dropped in handleMessage
(servers.get finds nothing), timing out after 120s, and every later
request failed 'not running' while the replacement process leaked,
alive but unreachable. Only delete the entry when the exiting process
is still the registered generation. Node-side counterpart of the
browser-side pid-generation guard from f13e112.
@sonarqubecloud

sonarqubecloud Bot commented Aug 2, 2026

Copy link
Copy Markdown

@abose
abose merged commit 8a0684d into main Aug 3, 2026
14 of 21 checks passed
@abose
abose deleted the lspFix branch August 3, 2026 03:11
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.

1 participant