Thank you for the bug report
Bug description
In Emacs + spacemacs, when opening a .js file in js2-mode with lsp + ts-ls as backend, I get the error message "Error running timer: (error "The package typescript is not installed. Unable to find tsserver")". This used to happen a couple of years ago due to an lsp upstream bug (#4254 ), then got resolved. Now it came up again.
I've installed node via mise globally and installed typescript globally with npm i -g typescript.
Despite Emacs having detected mise's node installation location and having installed typescript and typescript-language-server under ~/.emacs.d/.cache/lsp/npm where they're picked up by Emacs, the problem persists, breaking lsp-mode for javascript and typescript modes.
Javascript / Typescript are the only modes exhibiting this behavior, all other modes I use work correctly, including those that use node-based language servers (json-ls, html-ls, css-ls).
Steps to reproduce
- Start Emacs
- Open a
.js or .tsx file
- Check the
*Messages* buffer
Expected behavior
lsp-mode is correctly enabled for javascript and typescript, loading ts-ls correctly.
Which Language Server did you use?
ts-ls
OS
MacOS
Error callstack
Anything else?
All of my toolchains are managed with mise, and all tools are correctly detected within Emacs (python, ruby, node).
Thank you for the bug report
lsp-moderelated packages.M-x lsp-start-plainBug description
In Emacs + spacemacs, when opening a
.jsfile injs2-modewithlsp+ts-lsas backend, I get the error message "Error running timer: (error "The package typescript is not installed. Unable to find tsserver")". This used to happen a couple of years ago due to anlspupstream bug (#4254 ), then got resolved. Now it came up again.I've installed
nodeviamiseglobally and installedtypescriptglobally withnpm i -g typescript.Despite Emacs having detected
mise'snodeinstallation location and having installedtypescriptandtypescript-language-serverunder~/.emacs.d/.cache/lsp/npmwhere they're picked up by Emacs, the problem persists, breakinglsp-modefor javascript and typescript modes.Javascript / Typescript are the only modes exhibiting this behavior, all other modes I use work correctly, including those that use
node-based language servers (json-ls,html-ls,css-ls).Steps to reproduce
.jsor.tsxfile*Messages*bufferExpected behavior
lsp-modeis correctly enabled for javascript and typescript, loadingts-lscorrectly.Which Language Server did you use?
ts-lsOS
MacOS
Error callstack
Anything else?
All of my toolchains are managed with
mise, and all tools are correctly detected within Emacs (python,ruby,node).