From afb148e19d6b887fb2d4bbcc35787f8afbb6420e Mon Sep 17 00:00:00 2001 From: Martin Sosic Date: Fri, 23 Jun 2023 12:44:43 +0200 Subject: [PATCH] wasp cli now exits with code 1 on internal errors. --- waspc/cli/exe/Main.hs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/waspc/cli/exe/Main.hs b/waspc/cli/exe/Main.hs index c945fe015..b373869fa 100644 --- a/waspc/cli/exe/Main.hs +++ b/waspc/cli/exe/Main.hs @@ -107,7 +107,9 @@ main = withUtf8 . (`E.catch` handleInternalErrors) $ do in threadDelay . (* microsecondsInASecond) handleInternalErrors :: E.ErrorCall -> IO () - handleInternalErrors e = putStrLn $ "\nInternal Wasp error (bug in compiler):\n" ++ indent 2 (show e) + handleInternalErrors e = do + putStrLn $ "\nInternal Wasp error (bug in compiler):\n" ++ indent 2 (show e) + exitFailure {- ORMOLU_DISABLE -} printUsage :: IO ()