Skip to content

Use hie-bios 0.15.0 #4582

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

Merged
merged 2 commits into from
May 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/setup-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ inputs:
cabal:
description: "Cabal version"
required: false
default: "3.10.2.0"
default: "3.14.2.0"
os:
description: "Operating system: Linux, Windows or macOS"
required: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ jobs:
matrix:
ghc: ['9.8', '9.10']
os: [ubuntu-latest]
cabal: ['3.10']
cabal: ['3.14']
example: ['cabal', 'lsp-types']

steps:
Expand Down
2 changes: 1 addition & 1 deletion cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ packages:
./hls-test-utils


index-state: 2025-04-19T07:34:07Z
index-state: 2025-05-06T13:26:29Z

tests: True
test-show-details: direct
Expand Down
2 changes: 1 addition & 1 deletion ghcide/ghcide.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ library
, Glob
, haddock-library >=1.8 && <1.12
, hashable
, hie-bios ^>=0.14.0
, hie-bios ^>=0.15.0
, hie-compat ^>=0.3.0.0
, hiedb ^>= 0.6.0.2
, hls-graph == 2.10.0.0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{-# LANGUAGE DeriveAnyClass #-}

Check warning on line 1 in ghcide/session-loader/Development/IDE/Session/Diagnostics.hs

View workflow job for this annotation

GitHub Actions / Hlint check run

Warning in module Development.IDE.Session.Diagnostics: Use module export list ▫︎ Found: "module Development.IDE.Session.Diagnostics where" ▫︎ Perhaps: "module Development.IDE.Session.Diagnostics (\n module Development.IDE.Session.Diagnostics\n ) where" ▫︎ Note: an explicit list is usually better

module Development.IDE.Session.Diagnostics where
import Control.Applicative
Expand Down Expand Up @@ -28,15 +28,17 @@
Depicts the cradle error in a user-friendly way.
-}
renderCradleError :: CradleError -> Cradle a -> NormalizedFilePath -> FileDiagnostic
renderCradleError (CradleError deps _ec ms) cradle nfp =
renderCradleError cradleError cradle nfp =
let noDetails =
ideErrorWithSource (Just "cradle") (Just DiagnosticSeverity_Error) nfp (T.unlines $ map T.pack userFriendlyMessage) Nothing
in
if HieBios.isCabalCradle cradle
then noDetails & fdLspDiagnosticL %~ \diag -> diag{_data_ = Just $ Aeson.toJSON CradleErrorDetails{cabalProjectFiles=absDeps}}
else noDetails
where
absDeps = fmap (cradleRootDir cradle </>) deps
ms = cradleErrorStderr cradleError

absDeps = fmap (cradleRootDir cradle </>) (cradleErrorDependencies cradleError)
userFriendlyMessage :: [String]
userFriendlyMessage
| HieBios.isCabalCradle cradle = fromMaybe ms $ fileMissingMessage <|> mkUnknownModuleMessage
Expand Down Expand Up @@ -87,7 +89,7 @@
surround start s end = do
guard (listToMaybe s == Just start)
guard (listToMaybe (reverse s) == Just end)
pure $ drop 1 $ take (length s - 1) s

Check warning on line 92 in ghcide/session-loader/Development/IDE/Session/Diagnostics.hs

View workflow job for this annotation

GitHub Actions / Hlint check run

Warning in parseMultiCradleErr in module Development.IDE.Session.Diagnostics: Use drop1 ▫︎ Found: "drop 1" ▫︎ Perhaps: "drop1"

multiCradleErrMessage :: MultiCradleErr -> [String]
multiCradleErrMessage e =
Expand Down
2 changes: 1 addition & 1 deletion stack-lts22.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ extra-deps:
- Diff-0.5
- floskell-0.11.1
- hiedb-0.6.0.2
- hie-bios-0.14.0
- hie-bios-0.15.0
- implicit-hie-0.1.4.0
- lsp-2.7.0.0
- lsp-test-0.17.1.0
Expand Down
1 change: 1 addition & 0 deletions stack.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ extra-deps:
- floskell-0.11.1
- hiedb-0.6.0.2
- implicit-hie-0.1.4.0
- hie-bios-0.15.0
- hw-fingertree-0.1.2.1
- monad-dijkstra-0.1.1.5
- retrie-1.2.3
Expand Down
Loading