Giter Site home page Giter Site logo

Comments (15)

weilbith avatar weilbith commented on May 27, 2024 3

Thanks for the kind hint!
I'll definitely give this a try to see if I can make it work this way. But in the end I would highly prefer to not have this configuration file. Especially because I need the update settings functionality to alternate linters and formatters on project basis.

from efm-langserver.

samkatt avatar samkatt commented on May 27, 2024 1

@weilbith I had similar issues in getting a linter to work with markdown (same error msg anyways). I ended up having no configurations within the nvim setup

require "lspconfig".efm.setup { }

But made sure the configurations were specified in $HOME/.config/efm-langserver/config.yaml. Not sure if you can make efm-langserver use spellcheck through such a config file, YMMV.

I also noticed you can try to increase the log level. I set it arbitrarily to 10 (as opposed to 1, that I saw in an example), which gave more information than just "languageID not supported".

# ..../config.yaml
log-file: /path/to/file
log-level: 10

languages:
    sh: ....

from efm-langserver.

weilbith avatar weilbith commented on May 27, 2024 1

Alright.Thanks for you help. I must admit that I can't tell what the exact issue was. But NeoVim still lacks in propagating Lua syntax errors in vim scripts. 😑
But it works now and I'm super happy and excited to use this language server now! 🥳

from efm-langserver.

kabouzeid avatar kabouzeid commented on May 27, 2024 1

Ok I fixed it, found an unmarshal error in the log. Thanks again for your help!

I had lintFormats = '%f:%l:%c: %m' in a linter for a different language. Changing it to lintFormats = { '%f:%l:%c: %m' } fixed it.

from efm-langserver.

weilbith avatar weilbith commented on May 27, 2024 1

I'm glad you managed to resolve your issue. 🤗

from efm-langserver.

gegoune avatar gegoune commented on May 27, 2024

This works for me:

local spellcheck =  {
  lintCommand = "shellcheck -f gcc -x -",
  lintStdin = true,
  lintFormats = {"%f:%l:%c: %trror: %m", "%f:%l:%c: %tarning: %m", "%f:%l:%c: %tote: %m"}
}

Seems like your lintFormats does not match shellcheck's output (no = in output).

from efm-langserver.

weilbith avatar weilbith commented on May 27, 2024

Good catch. I'm sorry I just copied the format.
But it still does not work. Now (not sure why) I get this message in the log each time I open the file in NeoVim:
2021/01/08 14:06:54 lint for LanguageID not supported: sh.

Except of having other looking on my configuration and search for errors, how could I further investigate here? Is there an option do to some kind of JSON-RPC requests to the server with curl or similar? Thinking about adding a custom handler for the diagnostic handling to NeoVim to get the direct response of the server and see if there is something in the "middleware" that goes wrong.

from efm-langserver.

weilbith avatar weilbith commented on May 27, 2024

I the linting command fails "inside" the efm server, can I somehow see this? Or if the output parsing fails (also after @cloggier his fix that shouldn't be the case) can I see the original output? In fact get some debugging linting. The log is very silent...

from efm-langserver.

kabouzeid avatar kabouzeid commented on May 27, 2024

@weilbith did you get it to work without the yaml config file? I have the same exact issue as you are describing.

from efm-langserver.

weilbith avatar weilbith commented on May 27, 2024

@weilbith did you get it to work without the yaml config file? I have the same exact issue as you are describing.

Yes. It does work. Though I must admit that I have not found the time/pressure to add many linter/formatter yet. Here the lspconfig part and here the actual configurations. But only stuff I have actually yet commited. 🙈
But that should be enough for you as example to follow. I hope it helps.

PS: The LspInfo command is quite useful to check things.

from efm-langserver.

kabouzeid avatar kabouzeid commented on May 27, 2024

Thank you! I'm already doing the same thing as in your config; I can't figure out why it's not working. The log always tells me lint for LanguageID not supported: sh...

from efm-langserver.

kabouzeid avatar kabouzeid commented on May 27, 2024

Configuring via config.yaml makes it work immediately, but this is not what I want :/

from efm-langserver.

weilbith avatar weilbith commented on May 27, 2024

Yes, as I wrote I had similar issues and then it kinda resolved itself. Sorry for that stupid statement. But I work on the AUR nightly binary package for NeoVim and update my plugins daily. And as both are under heavy development... 🤷🏾
Also it probably don't help, here my version:

  • efm-langserver 0.0.26 (rev: HEAD/go1.15.6)
  • NVIM v0.5.0-dev+1160-g0f7b6b2ef
  • lspconfig 26c499916ddac29675d316a099b376abf6a0aeaf

from efm-langserver.

kabouzeid avatar kabouzeid commented on May 27, 2024

Thanks for the version info. This is so weird, I'll look further into this and tell you when I find something :)

from efm-langserver.

dhruvinsh avatar dhruvinsh commented on May 27, 2024

I has similar issue as well, but turns out it was just config issue. #158

issue described here: #158 (comment)

from efm-langserver.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.