bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#62795: 29.0.90; eglot: gdscript default port is 6005


From: João Távora
Subject: bug#62795: 29.0.90; eglot: gdscript default port is 6005
Date: Sat, 15 Apr 2023 09:17:14 +0100

On Sat, Apr 15, 2023 at 9:07 AM Eli Zaretskii <eliz@gnu.org> wrote:
>
> > Date: Wed, 12 Apr 2023 18:33:01 +0800
> > From:  xiliuya via "Bug reports for GNU Emacs,
> >  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
> >
> > The default port for godot lsp is defined in gdscript_language_server.h 
> > file:
> > :
> > >     bool use_thread = false;
> > >     String host = "127.0.0.1";
> > >     int port = 6005;
> > >     static void thread_main(void *p_userdata);
> > patch:
> >
> > diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
> > index 10b6c0cc2ca..f61040af636 100644
> > --- a/lisp/progmodes/eglot.el
> > +++ b/lisp/progmodes/eglot.el
> > @@ -230,7 +230,7 @@ eglot-server-programs
> >                                  (erlang-mode . ("erlang_ls" "--transport" 
> > "stdio"))
> >                                  ((yaml-ts-mode yaml-mode) . 
> > ("yaml-language-server" "--stdio"))
> >                                  (nix-mode . ,(eglot-alternatives '("nil" 
> > "rnix-lsp")))
> > -                                (gdscript-mode . ("localhost" 6008))
> > +                                (gdscript-mode . ("localhost" 6005))
> >                                  ((fortran-mode f90-mode) . ("fortls"))
> >                                  (futhark-mode . ("futhark" "lsp"))
> >                                  (lua-mode . ,(eglot-alternatives
>
> João, should I install this?  Any idea why eglot.el uses an incorrect
> or outdated value?

I don't know.  It would be very hard to know.  Should Eglot not
work with those presumably older versions of whichever server is
running in localhost?

This is a very poor entry anyway in the db anyway.  I didn't even notice
that it's just assuming whatever is on localhost on that port is the
gdscript server.   IMO we shouldn't touch it, but I suggest to xiliuya
to show the output of "whatever-executable-launches-the-server --help".

If that executable allows specifying a port, which is probably does
then the :autoport solution can be used like in the ruby entry.
And then we can commit that solution.

Else, I even think this should be just removed entirely
from eglot-server-programs.  My intuition tells me it was added by
someone who just wanted eglot-ensure to work for them, but it's
very very brittle.  And that person could have easily added that
entry to the config in their configuration.

So in summary, no I don't think Eglot should be tracking this.

João





reply via email to

[Prev in Thread] Current Thread [Next in Thread]