LSP not starting when opening new project files
- Dominant language
- Emacs Lisp
- Stars
- 22.7k
- Forks
- 3.1k
- Avg merge
- 10h 46m
- Merged PRs (30d)
- 4
Description
### I confirm that...
- [X] I have searched the [issue tracker](https://github.com/doomemacs/doomemacs/issues), [documentation](https://docs.doomemacs.org), [FAQ](https://docs.doomemacs.org/-/faq), [Discourse](https://discourse.doomemacs.org), and [Google](https://google.com), in case this issue has already been reported/resolved.
- [X] I have read "[How to Debug Issues](https://doomemacs.org/d/how2debug)", and will use it to provide as much information about this issue as possible.
- [X] The issue can be reproduced on the **latest** available commit of Doom.
- [X] The issue can be reproduced on a stable release of Emacs, such as 27 or 28. *(Doom does not support development builds like 29+ or any version ending in .50 or .9x)*
### Expected behavior
* Open workspace `X` file `file1.tsx`
* LSP starts/works when in `file1.tsx`
* Move to another file (Go To Definition or normal open another file) `file2.tsx`
* LSP starts/works when in `file2.tsx`
### Current behavior
* Open workspace `X` file `file1.tsx`
* LSP starts/works when in `file1.tsx`
* Move to another file (Go To Definition or normal open another file) `file2.tsx`
* LSP DOES NOT starts/works when in `file2.tsx`
### Steps to reproduce
1. Open doom emacs
2. Switch to project and open any tsx file
3. Check if LSP starts (it should)
4. Move to another file (either go to definition or just open another file) from the same project.
5. LSP does not work/start in that file
I noticed `lsp-describe-session` does not include `file2.tsx` upon opening it. If I run `M-x lsp` then `file2.tsx` is added to the session and LSP works as expected for that file.
PS:
* Project root is correctly set: `projectRoot/../../file1.tsx` and `projectRoot/../../file2.tsx`
* Using ts-ls language server
### System Information
https://pastebin.com/0LG33Yeu
Contributor guide
Assessment
This issue has not been assessed yet.