From 80d86ec24d3c33aca074a9fbf58b3dcfb2b7eb06 Mon Sep 17 00:00:00 2001 From: Doug Beardsley Date: Tue, 17 Aug 2021 19:02:56 -0400 Subject: [PATCH] Fix build failure (#65) --- exec/Chainweb/Coins.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/exec/Chainweb/Coins.hs b/exec/Chainweb/Coins.hs index 1da14b8a..babcfe83 100644 --- a/exec/Chainweb/Coins.hs +++ b/exec/Chainweb/Coins.hs @@ -54,7 +54,8 @@ newtype CsvTime = CsvTime { _csvTime :: UTCTime } instance CSV.FromField CsvTime where parseField f = either fail pure ev where - ev = fmap CsvTime . parseTimeM True defaultTimeLocale "%FT%TZ" =<< + ev = maybe (Left $ "Error parsing CsvTime " <> show f) (Right . CsvTime) . + parseTimeM True defaultTimeLocale "%FT%TZ" =<< bimap show T.unpack (decodeUtf8' f) newtype MinerRewards = MinerRewards