0

I tried to use fortls language server (installed via Mason) in Lunarvim, but lvim keeps showing "LSP inactive". The Python and the lua language server are working without any problem

I've restarted it (LspResart) and uninstalled and reinstalled it via Mason. Even the older 2.12.0 version, but every time the same behavior.

I'm on Ubuntu 20.04.6 LTS.

Can anyone who uses fortls in lvim/nvim give me a hint where the problem could be?

fpl
  • 1
  • 2
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Aug 17 '23 at 13:20
  • Please provide with contents of you _lsp.log_ you can see path to it at lsp info window: _:LspInfo_ command. – Monsieur Merso Aug 20 '23 at 14:46
  • It seems to be empty, is there a way to switch it to "verbose"? – fpl Aug 20 '23 at 14:57
  • I'm not familiar with lunarvim, can you show _LspInfo_ contents? – Monsieur Merso Aug 24 '23 at 16:16
  • 'Language client log: /home/XXXi/.local/state/nvim/lsp.log Detected filetype: fortran 0 client(s) attached to this buffer: Other clients that match the filetype: fortran Config: fortls Refer to :h lspconfig-root-detection for help. filetypes: fortran root directory: Not found. cmd: fortls --notify_init --hover_signature --hover_language=fortran --use_signature_help cmd is executable: true autostart: true custom handlers: Configured servers list: fortls` – fpl Aug 25 '23 at 18:37

1 Answers1

0

I assume you are using fortls (https://github.com/fortran-lang/fortls), which in that case you might want to have a look at the docs on setting fortls up for neovim

Installation

Docs: https://fortls.fortran-lang.org/quickstart.html#download

FYI: make sure that where you install fortls is in your PATH.

neovim Integration

Docs: https://fortls.fortran-lang.org/editor_integration.html#neovim


As a final note, fortls has also a Command Line Interface (CLI), so you can test it works by opening a terminal and typing something along the lines of

fortls --debug_filename your_file.f90 --debug_parser

The output should be a parsed version of your file.

gnikit
  • 1,031
  • 15
  • 25
  • i've already installed fortls like that and using it in vscode for a while without problems. I've also thested the CLI (its --debug_filepath not --debug_filename) and its working. As mentionend in my question ive installed it via Mason (like all other LSPs i am using), which semms to install a seperate executable, which i tested via the cli too. i still get the "LSP inactive" in the bottom right corner. – fpl Aug 26 '23 at 09:31
  • Mason is not an officially supported download channel for `fortls`. That being said if you say that the mason-installed version of `fortls` works from its CLI, then it is probably something in your `neovim` settings. Please edit your question to provide additional information about your configuration and all relevant logs. – gnikit Aug 26 '23 at 16:14