-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HLS-bundled Fourmolu is outdated (< 0.12) #978
Comments
Ugh. I don't understand how this happened. |
What is the required Cabal incantation? I'll see about translating it to |
One way would be to run |
Hmm, I'm able to convince HLS (via
The same HLS pin builds fine without the I'm not sure how to resolve this. Any ideas? |
This looks like an incompatibility between
This also explains why it builds without the constraint: it can just pick an older version of fourmolu which has compatible bounds with hlint. I think this will be fixed in the next release of hlint, which will contain ndmitchell/hlint#1470 (already merged upstream). I guess we could build hlint from git? |
Hmm, so how does anyone get HLS working with |
I imagine that one can have either
by setting the appropriate flags (for HLS) and constraints (on fourmolu). Just the combination HLS+hlint+fourmolu-0.12 seems problematic (without an unreleased hlint). [Take this with a pinch of salt, I haven't tested anything] |
Yes, I believe @brprice is correct. I've asked HLint about making a release: ndmitchell/hlint#1477 (comment). There are a few options:
|
As this doesn't fix @georgefst's issues, I don't see any point in changing our pin for now, then. We'll wait for, at the latest, the HLS 2.0 release, and hopefully that will fix all the things. |
Not sure whether this is fixed in 2.0 because it has other issues: #1009 |
It was intended that #883 would cause Fourmolu 0.12 to be used as the dependency version for HLS' Fourmolu plugin. Unfortunately, this doesn't seem to have been the case. We bumped to a version of HLS which supports Fourmolu 0.12, and all else being equal, the latest version of a library should be picked up, so I'm not sure why this has happened.
We should force HLS to use Fourmolu 0.12, but I can't personally work out the right Haskell.Nix incantation to set the constraint.
To demonstrate that this is the case, notice that the HLS-bundled Fourmolu ignores
single-constraint-parens
, e.g. when formattingn = 1 :: Num a => a
, so long as the HLShaskell.plugin.fourmolu.config.external
isn't enabled.The text was updated successfully, but these errors were encountered: