emacs-lsp / lsp-mode

Emacs client/library for the Language Server Protocol
https://emacs-lsp.github.io/lsp-mode
GNU General Public License v3.0
4.75k stars 869 forks source link

Warning (lsp-mode): Unknown notification: workspace/semanticTokens/refresh #3437

Open rieje opened 2 years ago

rieje commented 2 years ago

Thank you for the bug report

Bug description

Got warning message popup when lsp-mode and lua-language-server enabled:

Warning (lsp-mode): Unknown notification: workspace/semanticTokens/refresh

Steps to reproduce

Enable lua-language-server for lsp-mode.

Expected behavior

No warning popup.

Which Language Server did you use?

lsp-language-server (latest, 2.6.7)

OS

Linux

Anything else?

Probably related comment from closed issue.

yyoncho commented 2 years ago

@ericdallo @sebastiansturm - any clue?

ericdallo commented 2 years ago

Odd, we do implement support for that notification here , or do we need to handle a server request differently from a server notification @yyoncho ?

yyoncho commented 2 years ago

@rieje as I requested in the original issue, can you test with the latest versions of everything, preferably with M-x lsp-start-plain?

rieje commented 2 years ago

M-x lsp-start-plain then installed lua-mode and enabled on buffer for lua file, same issue.

yyoncho commented 2 years ago

Odd, we do implement support for that notification here , or do we need to handle a server request differently from a server notification @yyoncho ?

@ericdallo this is registration for request, while the warning is for missing notification handler. They should be registered here - https://github.com/emacs-lsp/lsp-mode/blob/master/lsp-mode.el#L6208 .

At the same time token refresh is listed as a request, not notification: https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#semanticTokens_refreshRequest so I believe that the issue should be fixed on the server unless we somehow mistake request with notification.

ericdallo commented 2 years ago

At the same time token refresh is listed as a request, not notification: https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#semanticTokens_refreshRequest so I believe that the issue should be fixed on the server unless we somehow mistake request with notification.

Agreed, it's something to be fixed on server indeed IMO

sebastiansturm commented 2 years ago

thanks for resolving this so quickly @yyoncho and @ericdallo! I'll just add that the same issue came up previously (https://github.com/emacs-lsp/lsp-mode/issues/3029), in response to which a PR to the lua language server had been opened (https://github.com/sumneko/lua-language-server/pull/633) which seems to have been merged into the lua language server in August 2021