Skip to content

Commit 28af3f0

Browse files
committed
Create log directory if it does not exist
1 parent 25825b0 commit 28af3f0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cardano-testnet/src/Testnet/Runtime.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,8 +297,8 @@ startLedgerNewEpochStateLogging testnetRuntime tmpWorkspace = withFrozenCallStac
297297

298298
liftIOAnnotated $ IO.doesDirectoryExist logDir >>= \case
299299
True -> pure ()
300-
False -> do
301-
throwString $ "Log directory does not exist: " <> logDir <> " - cannot start logging epoch states"
300+
False ->
301+
void $ createDirectoryIfMissingNew logDir
302302

303303
liftIOAnnotated (IO.doesFileExist logFile) >>= \case
304304
True -> return ()

0 commit comments

Comments
 (0)