-
-
Notifications
You must be signed in to change notification settings - Fork 898
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Godot GDScript problems #2127
Comments
The issue is that servers from time to time introduce new notifications and we have to adjust lsp-mode accordingly.
@kiennq is using company-box - maybe we will need logs from the server to figure out
The easy fix is to bind this notifications to nil - see https://github.com/yyoncho/lsp-mode/blob/master/clients/lsp-hack.el#L47 |
This indicates more serious issues, mostly due to
I'm using a fork of |
I'm a bit stymied by that. I've reproduced the issue with
That gist was narrowed down to a few keystrokes. I just did another one. Here were my steps
Result: at least 50,000 lines. 100,000 if I cancel the Is there something I could do differently to narrow this down? Most of that appears to be happening as a direct result of Editing to add gist link: https://gist.github.com/mnewt/20339c243dba4a5138c1354e3a0c78fa#file-lsp-log-2 |
I've taken a look at this, indeed no The |
Correct. Invoking |
I'm also seeing this lsp warning issue. Is there a way to disable the warning buffer from popping up everytime? |
@sebastiencs for |
Someone should bind the missing notification handlers to no-op like this - https://github.com/yyoncho/lsp-mode/blob/master/clients/lsp-hack.el#L47 |
@yyoncho Thanks, I did try to add a notification handler: (lsp-register-client
(make-lsp-client :new-connection (lsp-gdscript-tcp-connect-to-port)
:major-modes '(gdscript-mode)
:server-id 'gdscript
;; Ignore unsupported messages.
:notification-handlers (lsp-ht ("executeCommand" 'ignore)))) But I still get this in
And this in
Did I do what you had in mind? |
You have to use "gdscript/capabilities" as a key to get rid of that notification. For the one with nil name, I will need the input of lsp--on-notification which you can get when you do |
That's great, I added gdscript/capabilities. I'm learning! Here's an example of trace output when the nil notification pops up:
I wish I could say it's plain to me what the problem is, but I'm afraid it's not. Perhaps you could translate for me? By the way @yyoncho thank you for this amazing project that works shockingly well the vast majority of the time and for taking the time to help me with my problem! |
This doesn't seem to the notification that is causing the issue since it is |
Coming in late to the thread, but Im having the warnings issues as well.
It looks like you already have this on a branch @yyoncho. Is there a reason that this can't just be opened as a PR to upstream it? If not, what needs to be done so that it can? FWIW, Im also seeing the following in the Output console in Godot...
|
Ok, Ive got some custom code in my emacs config that is suppressing notifications for...
but I am still getting several...
Is there a way to globally silence calls to |
Output from I wasnt sure what section of this would be relevant so I took a large sampling of the `*trace-output*`
|
There were some issues on the side of Godot's language server. In particular, in the past, with some specification not being respected. I sponsored someone to fix these issues. Could you try with the recently released Godot 3.3 and see if you still have the same problems? EDIT: I can confirm two warnings are still here at least: gdscript/capabilities and the nil notification. |
lsp
with GDScript mostly works fine but has two visible issues:Problem 1
It repeatedly logs warnings and pops open the
*Warnings*
buffer. If I close the*Warnings*
buffer, it just opens it up again. I presume there is a capability mismatch between Godot and lsp. Example*Warnings*
entries:lsp-log: https://gist.github.com/mnewt/20339c243dba4a5138c1354e3a0c78fa
The first warning will pop up when
lsp
is started and the subsequent warnings will pop up from time to time while editing.Problem 2
company
completion doesn't work whencompany-box-mode
is enabled. I think I've narrowed down the problem to what happens inlsp-completion--exit-fn
. It goes something like this:lsp-completion-item
plist entry has inside it:label
and:insert-text?
company-mode
is enabled butcompany-box-mode
is not,:insert-text?
is nil.company-mode
andcompany-box-mode
are enabled,:insert-text?
is""
, solsp-completion--exit-fn
inserts that blank string.I've confirmed that inserting this in
lsp-completion--exit-fn
does indeed cause the candidate to be inserted as expected:Questions
*Warnings*
buffer to not pop up every time one occurs?lsp
orcompany-box
? Can you clarify what is going on there?Reproduction Steps:
emacs -Q
Now, open a GDScript file and try to insert a completion using company, e.g.:
And do
M-x company-complete
, thenM-x company-complete-selection
Versions
lsp: 7.0.1 (commit 1185a48)
GNU Emacs 28.0.50 (build 1, x86_64-apple-darwin19.6.0, NS appkit-1894.60 Version 10.15.6 (Build 19G2021)) of 2020-08-29
Godot 3.2.2
The text was updated successfully, but these errors were encountered: