delitrem

delitrem

unless Guix is the OS

It is a Nix-like Linux-based OS from GNU.

could you try downloading the latest release from the github releases instead of running it from source?

Yes, but I had another issue (epmd is running and in $PATH):

[server-notification] Thu Oct  5 00:19:28 2023:
(:jsonrpc "2.0" :method "window/logMessage" :params
          (:message "[NextLS] Runtime for folder ~/src/elixir/test_next_ls/ failed to initialize" :type 1))
[server-notification] Thu Oct  5 00:19:28 2023:
(:jsonrpc "2.0" :method "window/logMessage" :params
          (:message "[NextLS] The runtime for ~/src/elixir/test_next_ls/ has crashed with reason: {:shutdown, :portdown}" :type 1))

Well, it seems this misbehaviour could be somehow connected with Guix (or something weird there), I will have some free time during next weekend and will take a look to figure out what is going on.

0
Post #29
halostatue

halostatue

And this is the main reason why, despite how nice NextLS appears, it will probably never ben an option for me. As of October 2023, there is no Neovim GUI that is even ⅛ as usable as MacVim, and I am unwilling to give up the native OS integration for one of the many subpar Neovim GUIs or to use it in the shell.

I’d love to try NextLS, but I’m not changing my editor for a language server.

0
Post #30
mhanberg

mhanberg OP

Expert LSP Core Team

Next LS is usable in any editor that supports the language server protocol, including Vim.

In order to improve my messaging, what lead you to believe it doesn’t work with Vim?

I’ll admit I don’t have setup instructions for Vim yet, but that’s mostly because I haven’t had anyone ask about it yet.

1
Post #31
delitrem

delitrem

Well, it was quite trivial to localize a bug.
The problem was because of difference between names of node started as ‘runtime’ and remote calls. The first one used ‘localhost’ by default and the second one – :inet.gethostname().
The fix should be something like this: https://github.com/elixir-tools/next-ls/compare/main...klalafudaklalafu:next-ls:node-hostname-fix

To reproduce:

% cat /etc/hostname
kraken
% cat /etc/hosts
127.0.0.1	localhost	kraken
::1	localhost	kraken

BTW, am I right, autocomplete is not supported yet?

0
Post #32
sodapopcan

sodapopcan

I never said I used MacVim (or gui vim) :sweat_smile: I’m just confused by your quoting me, not that it’s a big deal or anything :sweat_smile:

0
Post #33
mhanberg

mhanberg OP

Expert LSP Core Team

that is correct, it’s next on the todo list!

i’ll take a look at that patch!

2
Post #34
mhanberg

mhanberg OP

Expert LSP Core Team

CleanShot 2023-10-04 at 20.41.31
CleanShot 2023-10-04 at 20.41.311200×750 71.5 KB

I got it running using GitHub - yegappan/lsp: Language Server Protocol (LSP) plugin for Vim9 · GitHub, but i found a bug in it’s client, and I don’t know vim9script to fix it. bug

This is mostly to demonstrate that it can work in Vim, but I’m still curious as to what brought you to the conclusion that it wouldn’t.

0
Post #35
halostatue

halostatue

I somewhat misstated my objections. I know that as a language server, it will work with any existing language client. But the existence of elixir-tools.nvim as a “first-class” tool suggests that vim support is extremely low on your priority list.

Because I don’t use neovim (for reasons I stated above), I can’t say whether there is anything in elixir-tools.nvim that requires neovim support, but I tend to avoid even investigating neovim-only tools — as the moment that there’s Lua configuration, I know that I can’t use it in my editor.

I had considered opening a ticket asking about vim support some months ago, but between getting extremely busy and not caring enough, I never got around to doing so and wasn’t motivated to say anything until yesterday.

0
Post #36
mhanberg

mhanberg OP

Expert LSP Core Team

Your previous statements were extremely bold and mis-informative for anyone else reading this, so I suggest that you consider asking the questions prior to stating assumptions.

But, thanks for clarifying. Vim is on the radar, I just don’t have anyone in my immediate circle that uses Vim, so in a world of having a million things to do, I didn’t get around to documenting the setup.

Last night, I was able to get it working with yegappan/lsp (although it has an outstanding bug), prabirshrestha/vim-lsp, and dense-analysis/ALE.

I will update all of the setup instructions on the README and website once I can fix the yegappan/lsp bug as well as the ALE pull request is merged.

If you end up trying it with any of those, or use a different LSP client and have any questions, I’d be happy to help!

2
Post #37
mhanberg

mhanberg OP

Expert LSP Core Team

Howdy folks!

I’ve added a “Motivation” blurb and a “Next LS FAQ” section to the website, hopefully that answers any questions folks have had for why I chose to make a new project rather than contribute to the existing project(s).

Motivation: elixir-tools | elixir-tools
Next LS FAQ: Quickstart | elixir-tools

The elixir-tools Update Vol. 4 will be coming out in the next few weeks as well.

Take care!

8
Post #38