hoovercj/vscode-haskell-linter

Hlint not appearing, or doing anything..?

samwalls opened this issue · 9 comments

I'm on the latest vscode on Ubuntu 14.04 with hlint 1.8.53. I'm not getting any code suggestions, not even an indication of something happening. I have tried with and without these settings { "haskell.hlint.executablePath": "/usr/bin/hlint", "haskell.hlint.run": "onType" }

I know that the path is correct, as anything else produces a warning at the top of the screen.
How do I go about helping the situation?

also note, running hlint on the same file from the command line does produce suggestions

I'lll look into this. What version of VS Code are you using?

You said latest. I'm blind. I assume you mean v0.10.8?

On Windows I just updated VS Code, installed the extension and hlint (v1.9.28) and it is making the suggestions I would expect (accepting those suggestions, though, is broken).

I'll look a bit deeper and hopefully have something for you today.

@samdeman22: I've checked on my Windows and Linux machines and both seem to work for me. So also just pushed an update to the marketplace with improved logging that might help find the problem. Please update the extension to version 0.0.5 and add this line to your user settings or workspace settings:

"haskell.hlint.logLevel": "log"

Then use the command palette to open the developer tools and see if there is any output that looks helpful.

Well, there are some error reports indeed. This shows what I get, all the stuff at the bottom is where I type something and it tries to start hlint.

well then, checking a hlint changelog I can now see that the --json flag was only added after 1.9.1 - I have 1.8.53 for some reason. I'll try with an updated version if I can get it.

ah, apparently 14.04 doesn't get 1.9.21 for some reason, I temporarily added the wily universe and managed to get the right version, it works now. But what this means that anyone running 14.04 ubuntu will not get the extension working by default.
EDIT: what I said, I couldn't get it working through apt-get, however the haskell package manager cabal might be able to get it.

Thank you for the update! Apologies for not responding sooner, I've been traveling and haven't had a chance to follow up.

I'd love to document this but the marketplace doesn't have an easy way to update READMEs aside from bumping the version. I'll be traveling again for another week or so, but hopefully after that I can justify a version bump by throwing in a version check and notifying users if their hlint version is too low.

Documented a minimum hlint version in the README.