Skip to content

Commit

Permalink
Upgrade to ouroboros-network-0.3.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
coot committed Nov 24, 2022
1 parent 2c24d1b commit 3cda6f4
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 10 deletions.
22 changes: 21 additions & 1 deletion cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ repository cardano-haskell-packages
-- See CONTRIBUTING for information about these, including some Nix commands
-- you need to run if you change them
index-state: 2022-09-27T00:00:00Z
index-state: cardano-haskell-packages 2022-11-10T12:59:24Z
index-state: cardano-haskell-packages 2022-11-24T00:00:00Z

packages:
cardano-api
Expand Down Expand Up @@ -109,6 +109,26 @@ constraints:
, io-classes == 0.3.0.0
, typed-protocols == 0.1.0.1
, typed-protocols-examples == 0.1.0.1
, cardano-ledger-alonzo == 0.1.0.0
, cardano-ledger-babbage == 0.1.0.0
, cardano-ledger-byron == 0.1.0.0
, cardano-ledger-byron-test == 1.3.0
, cardano-ledger-conway == 0.1.0.0
, cardano-ledger-core == 0.1.0.0
, cardano-ledger-pretty == 0.1.0.0
, cardano-ledger-shelley == 0.1.0.0
, cardano-ledger-shelley-ma == 0.1.0.0
, cardano-ledger-shelley-test == 0.1.0.0
, cardano-crypto-test == 1.3.0
, cardano-crypto-wrapper == 1.3.0
, byron-spec-chain == 0.1.0.0
, byron-spec-ledger == 0.1.0.0
, set-algebra == 0.1.0.0
, small-steps == 0.1.0.0
, small-steps-test == 0.1.0.0
, vector-map == 0.1.0.0
, cardano-data == 0.1.0.0


extra-packages:
ouroboros-consensus-cardano-tools == 0.1.0.1
Expand Down
2 changes: 1 addition & 1 deletion cardano-api/cardano-api.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ library
, ouroboros-consensus-cardano
, ouroboros-consensus-protocol
, ouroboros-consensus-shelley
, ouroboros-network ^>= 0.2
, ouroboros-network ^>= 0.3
, ouroboros-network-framework ^>= 0.2
, parsec
, plutus-ledger-api
Expand Down
4 changes: 2 additions & 2 deletions cardano-node/cardano-node.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -164,12 +164,12 @@ library
, network-mux ^>= 0.2
, nothunks
, optparse-applicative-fork
, ouroboros-consensus ^>= 0.1.0.2
, ouroboros-consensus ^>= 0.1.0.3
, ouroboros-consensus-byron
, ouroboros-consensus-cardano
, ouroboros-consensus-protocol
, ouroboros-consensus-shelley
, ouroboros-network ^>= 0.2
, ouroboros-network ^>= 0.3
, ouroboros-network-framework ^>= 0.2
, psqueues
, safe-exceptions
Expand Down
3 changes: 2 additions & 1 deletion cardano-node/src/Cardano/Node/Tracing/Tracers/Consensus.hs
Original file line number Diff line number Diff line change
Expand Up @@ -561,11 +561,12 @@ instance (HasHeader header, ConvertRawHash header) =>
mconcat [ "kind" .= String "AddedFetchRequest" ]
forMachine _dtal BlockFetch.AcknowledgedFetchRequest {} =
mconcat [ "kind" .= String "AcknowledgedFetchRequest" ]
forMachine _dtal (BlockFetch.SendFetchRequest af) =
forMachine _dtal (BlockFetch.SendFetchRequest af gsv) =
mconcat [ "kind" .= String "SendFetchRequest"
, "head" .= String (renderChainHash
(renderHeaderHash (Proxy @header))
(AF.headHash af))
, "deltaq" .= toJSON gsv
, "length" .= toJSON (fragmentLength af)]
where
-- NOTE: this ignores the Byron era with its EBB complication:
Expand Down
9 changes: 8 additions & 1 deletion cardano-node/src/Cardano/Tracing/OrphanInstances/Network.hs
Original file line number Diff line number Diff line change
Expand Up @@ -1098,17 +1098,24 @@ instance ToObject SlotNo where
mconcat [ "kind" .= String "SlotNo"
, "slot" .= toJSON (unSlotNo slot) ]

instance ToJSON PeerGSV where
toJSON PeerGSV { outboundGSV = GSV outboundG _ _
, inboundGSV = GSV inboundG _ _
} =
Aeson.object ["G" .= (realToFrac (outboundG + inboundG) :: Double)]

instance (HasHeader header, ConvertRawHash header)
=> ToObject (TraceFetchClientState header) where
toObject _verb BlockFetch.AddedFetchRequest {} =
mconcat [ "kind" .= String "AddedFetchRequest" ]
toObject _verb BlockFetch.AcknowledgedFetchRequest {} =
mconcat [ "kind" .= String "AcknowledgedFetchRequest" ]
toObject _verb (BlockFetch.SendFetchRequest af) =
toObject _verb (BlockFetch.SendFetchRequest af gsv) =
mconcat [ "kind" .= String "SendFetchRequest"
, "head" .= String (renderChainHash
(renderHeaderHash (Proxy @header))
(AF.headHash af))
, "deltaq" .= toJSON gsv
, "length" .= toJSON (fragmentLength af)]
where
-- NOTE: this ignores the Byron era with its EBB complication:
Expand Down
2 changes: 1 addition & 1 deletion cardano-submit-api/cardano-submit-api.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ common mtl { build-depends: mtl
common network { build-depends: network >= 3.1.2.1 }
common optparse-applicative-fork { build-depends: optparse-applicative-fork >= 0.16.1.0 }
common ouroboros-consensus-cardano { build-depends: ouroboros-consensus-cardano >= 0.1.0.0 }
common ouroboros-network { build-depends: ouroboros-network >= 0.1.0.0 }
common ouroboros-network { build-depends: ouroboros-network >= 0.3.0.0 }
common prometheus { build-depends: prometheus >= 2.2.2 }
common protolude { build-depends: protolude >= 0.3.0 }
common servant { build-depends: servant >= 0.18.2 }
Expand Down
6 changes: 3 additions & 3 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3cda6f4

Please sign in to comment.