Skip to content

Commit

Permalink
wip Change chainSync to use Read.ChainTip
Browse files Browse the repository at this point in the history
  • Loading branch information
HeinrichApfelmus committed Apr 17, 2024
1 parent 4caf872 commit bbe8777
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/network-layer/src/Cardano/Wallet/Network.hs
Expand Up @@ -113,7 +113,7 @@ import qualified Internal.Cardano.Write.Tx as Write
data NetworkLayer m block = NetworkLayer
{ chainSync
:: Tracer IO ChainFollowLog
-> ChainFollower m Read.ChainPoint BlockHeader (NonEmpty block)
-> ChainFollower m Read.ChainPoint Read.ChainTip (NonEmpty block)
-> m ()
-- ^ Connect to the node and run the ChainSync protocol.
-- The callbacks provided in the 'ChainFollower' argument
Expand Down
Expand Up @@ -86,6 +86,7 @@ import Cardano.Wallet.Network.Implementation.Ouroboros
)
import Cardano.Wallet.Network.Implementation.Types
( fromOuroborosPoint
, fromOuroborosTip
, toOuroborosPoint
)
import Cardano.Wallet.Network.Implementation.UnliftIO
Expand Down Expand Up @@ -480,15 +481,14 @@ withNodeNetworkLayerBase
withStats $ \trChainSyncLog -> do
let mapB = getBlockHeader getGenesisBlockHash
mapP = fromOuroborosPoint
let blockHeader = fromTip' gp
let client =
mkWalletClient
(mapChainSyncLog mapB mapP >$< trChainSyncLog)
pipeliningStrategy
(mapChainFollower
toOuroborosPoint
mapP
blockHeader
fromOuroborosTip
id
follower
)
Expand Down

0 comments on commit bbe8777

Please sign in to comment.