lsp-treemacs icon indicating copy to clipboard operation
lsp-treemacs copied to clipboard

Error list keeps showing old cached results after the first render

Open setzer22 opened this issue 2 years ago • 5 comments

I've updated my emacs packages, and I noticed this issue. It seems to be related (or identical) to #149, but I've been able to reproduce this in other language servers I use (clojure and rust), which leads me to believe it is a general issue with lsp-treemacs itself, and not something that depends on the language.

The problem is the following: When I open a project, LSP diagnostics work okay in the buffer, and the first time I launch lsp-treemacs-error-list, I see the correct output. If I then make any changes to my LSP setup, lsp-treemacs-error-list keeps showing the old errors indefinitely. I haven't found a way to make it refresh the contents other than restarting emacs.

This is a quick screen recording of my interaction: emacs_bug

I was able to successfully bisect the issue to the following commit: e66865623ca1fa4a5a7b6f81901dc5ed21a58acc

Unfortunately, the commit is large enough that I cannot continue debugging without a better understanding of the codebase. This seems to be a caching issue, and the fact there's multiple references to caches in the commit source makes me believe that is the case.

setzer22 avatar Feb 20 '23 18:02 setzer22

Same issue working with Rust

zoechi avatar Mar 02 '23 07:03 zoechi

Same issue with Haskell

shapr avatar Apr 04 '23 20:04 shapr

Same with lsp-java and lsp-treemacs-references.

SreenivasVRao avatar Apr 06 '23 13:04 SreenivasVRao

Unable to repro. Can you verify that it does not work with M-x lsp-start-plain?

yyoncho avatar Apr 06 '23 17:04 yyoncho

(updated my comment to mention lsp-treemacs-references which was causing problems on DOOM emacs.)

M-x lsp-start-plain works fine. thanks for the tip @yyoncho - wasn't aware of this one before. Unsure what's causing this then.

SreenivasVRao avatar Apr 06 '23 19:04 SreenivasVRao