From 95cb9e70e3a32ba47e05ab97f10c2fb8715e20cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ondr=CC=8Cej=20S=CC=8Cebek?= Date: Thu, 3 Aug 2023 10:50:08 +0200 Subject: [PATCH] Put errors to stderr --- src/Swarm/Doc/Pedagogy.hs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Swarm/Doc/Pedagogy.hs b/src/Swarm/Doc/Pedagogy.hs index d26b495e0..2da509f04 100644 --- a/src/Swarm/Doc/Pedagogy.hs +++ b/src/Swarm/Doc/Pedagogy.hs @@ -161,9 +161,8 @@ loadScenarioCollection :: IO ScenarioCollection loadScenarioCollection = simpleErrorHandle $ do entities <- ExceptT loadEntities (failures, loadedScenarios) <- liftIO $ loadScenariosWithWarnings entities - when (notNull failures) $ - liftIO $ - hPutStrLn stderr "Loading failures: " >> mapM_ (T.putStrLn . prettyFailure) failures + when (notNull failures) . liftIO $ + hPutStrLn stderr "Loading failures: " >> mapM_ (T.hPutStrLn stderr . prettyFailure) failures return loadedScenarios renderUsagesMarkdown :: CoverageInfo -> Text