File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed
ghcide/session-loader/Development/IDE Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ packages:
66 ./ghcide
77 ./hls-plugin-api
88 ./hls-test-utils
9+ -- ../hiebios
910
1011
1112index-state : 2024-10-21T00:00 :00Z
@@ -46,3 +47,8 @@ constraints:
4647if impl(ghc >= 9.9 )
4748 -- https://github.com/haskell/haskell-language-server/issues/4324
4849 benchmarks : False
50+
51+ source-repository-package
52+ type : git
53+ location : https://github.com/soulomoon/hie-bios.git
54+ tag : 7dd19b547ba30b760053b5f796c439cba6ac6a07
Original file line number Diff line number Diff line change @@ -658,7 +658,10 @@ loadSessionWithOptions recorder SessionLoadingOptions{..} rootDir que = do
658658 | otherwise -> return (([renderPackageSetupException cfp GhcVersionMismatch {.. }], Nothing ),[] )
659659 -- Failure case, either a cradle error or the none cradle
660660 Left err -> do
661- errors <- mapM (makeError hieYaml cradle err) $ Set. toList pendingFiles
661+ let failedLoadingFiles = nub $ cfp: concatMap cradleErrorLoadingFiles err
662+ let remainPendingFiles = Set. delete cfp $ pendingFiles `Set.difference` Set. fromList failedLoadingFiles
663+ atomically $ forM_ remainPendingFiles (writeTQueue pendingFilesTQueue)
664+ errors <- mapM (makeError hieYaml cradle err) $ failedLoadingFiles
662665 return ((concat errors, Nothing ), maybe [] pure hieYaml ++ concatMap cradleErrorDependencies err)
663666
664667 let
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ data CradleErrorDetails =
2727 Depicts the cradle error in a user-friendly way.
2828-}
2929renderCradleError :: CradleError -> Cradle a -> NormalizedFilePath -> FileDiagnostic
30- renderCradleError (CradleError deps _ec ms) cradle nfp
30+ renderCradleError (CradleError deps _ec ms _fps ) cradle nfp
3131 | HieBios. isCabalCradle cradle =
3232 let (fp, showDiag, diag) = ideErrorWithSource (Just " cradle" ) (Just DiagnosticSeverity_Error ) nfp $ T. unlines $ map T. pack userFriendlyMessage in
3333 (fp, showDiag, diag{_data_ = Just $ Aeson. toJSON CradleErrorDetails {cabalProjectFiles= absDeps}})
You can’t perform that action at this time.
0 commit comments