add stage number to stagedDetails parser

And convert parser to attoparsec, probably faster.

Before, a parse failure threw the whole --stage output line in to the
filename, which was certianly a bad idea, so fixed that.
This commit is contained in:
Joey Hess 2020-07-08 14:54:29 -04:00
parent c1eaf5b930
commit 7347e50123
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
5 changed files with 42 additions and 27 deletions

View file

@ -99,11 +99,10 @@ knownUrls = do
void $ liftIO cleanup
return $ concat r
where
getkeyurls (f, s, _) = case urlLogFileKey f of
getkeyurls (f, s, _, _) = case urlLogFileKey f of
Just k -> zip (repeat k) <$> geturls s
Nothing -> return []
geturls Nothing = return []
geturls (Just logsha) =
geturls logsha =
map (decodeBS . fromLogInfo) . getLog
<$> catObject logsha