We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3e3d782 commit ac44a69Copy full SHA for ac44a69
ghcide/src/Development/IDE/LSP/LanguageServer.hs
@@ -141,7 +141,10 @@ runLanguageServer options inH outH getHieDbLoc defaultConfig onConfigurationChan
141
logInfo (ideLogger ide) $ T.pack $ "Registering ide configuration: " <> show initConfig
142
registerIdeConfiguration (shakeExtras ide) initConfig
143
144
- _ <- flip forkFinally (const exitClientMsg) $ runWithDb dbLoc $ \hiedb hieChan -> do
+ let handleHieDbException e = do
145
+ logError (ideLogger ide) (T.pack $ "Unexpected exception in hiedb thread: " <> show e)
146
+ exitClientMsg
147
+ _ <- flip forkFinally handleHieDbException $ runWithDb dbLoc $ \hiedb hieChan -> do
148
putMVar dbMVar (hiedb,hieChan)
149
forever $ do
150
msg <- readChan clientMsgChan
0 commit comments