From 0c8a571a769393f3a308927e023c475de4ffa56a Mon Sep 17 00:00:00 2001 From: Dmitry Zuikov Date: Wed, 19 Jul 2023 11:49:14 +0300 Subject: [PATCH] wip, log merging, debug-2 --- hbs2-peer/app/RefChan.hs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/hbs2-peer/app/RefChan.hs b/hbs2-peer/app/RefChan.hs index ed9870f6..55ac2cff 100644 --- a/hbs2-peer/app/RefChan.hs +++ b/hbs2-peer/app/RefChan.hs @@ -455,9 +455,18 @@ logMergeProcess _ q = do -- больше quorum подтверждений для актуальной головы r <- forM trans $ \href -> runMaybeT do + + debug $ "TO MERGE" <+> pretty href + blk <- MaybeT $ liftIO $ getBlock sto (fromHashRef href) + + debug $ "BLOCK OK" <+> pretty href + tran <- MaybeT $ pure $ deserialiseOrFail @(RefChanUpdate e) blk & either (const Nothing) Just + + debug $ "TRAN OK" <+> pretty href + case tran of Propose _ box -> do (pk, ProposeTran headRef box) <- MaybeT $ pure $ unboxSignedBox0 box