Skip to content

Commit

Permalink
Merge #1593
Browse files Browse the repository at this point in the history
1593: cardano-node: 1.10.1 -> 1.11.0 r=rvl a=rvl

# Issue Number

Relates to #1577 / ADP-83.

# Overview

- Updates cardano-node version in nix.
- Updates the cardano-haskell stack snapshot.
- Adds `cardano-cli` to the shell. I am hoping to use this in the integration tests.
- Build fixes

# Comments

WIP until input-output-hk/cardano-haskell#13 is merged.


Co-authored-by: Rodney Lorrimar <[email protected]>
  • Loading branch information
iohk-bors[bot] and rvl authored Apr 25, 2020
2 parents ce8a9fd + a250c6c commit 30bead7
Show file tree
Hide file tree
Showing 48 changed files with 114 additions and 95 deletions.
3 changes: 2 additions & 1 deletion default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ let
inherit pkgs commonLib src haskellPackages stackNixRegenerate;
inherit (jmPkgs) jormungandr jormungandr-cli;
# expose cardano-node, so daedalus can ship it without needing to pin cardano-node
inherit (pkgs) cardano-node;
inherit (pkgs) cardano-node cardano-cli;
inherit (haskellPackages.cardano-wallet-core.identifier) version;
# expose db-converter, so daedalus can ship it without needing to pin a ouroborus-network rev
inherit (haskellPackages.ouroboros-consensus-byron.components.exes) db-converter;
Expand Down Expand Up @@ -133,6 +133,7 @@ let
jormungandr
jormungandr-cli
cardano-node
cardano-cli
]) ++ (with pkgs; [
stack
cabal-install
Expand Down
4 changes: 2 additions & 2 deletions lib/byron/src/Cardano/Wallet/Byron.hs
Original file line number Diff line number Diff line change
Expand Up @@ -130,10 +130,10 @@ import Network.Wai.Handler.Warp
( setBeforeMainLoop )
import Network.Wai.Middleware.Logging
( ApiLog )
import Ouroboros.Network.CodecCBORTerm
( CodecCBORTerm )
import Ouroboros.Network.NodeToClient
( NodeToClientVersionData (..) )
import Ouroboros.Network.Protocol.Handshake.Version
( CodecCBORTerm )
import System.Exit
( ExitCode (..) )
import System.IOManager
Expand Down
4 changes: 2 additions & 2 deletions lib/byron/src/Cardano/Wallet/Byron/Compatibility.hs
Original file line number Diff line number Diff line change
Expand Up @@ -108,14 +108,14 @@ import Ouroboros.Network.Block
)
import Ouroboros.Network.ChainFragment
( HasHeader (..) )
import Ouroboros.Network.CodecCBORTerm
( CodecCBORTerm )
import Ouroboros.Network.Magic
( NetworkMagic (..) )
import Ouroboros.Network.NodeToClient
( NodeToClientVersionData (..), nodeToClientCodecCBORTerm )
import Ouroboros.Network.Point
( WithOrigin (..) )
import Ouroboros.Network.Protocol.Handshake.Version
( CodecCBORTerm )

import qualified Cardano.Crypto.Hashing as CC
import qualified Cardano.Wallet.Primitive.Types as W
Expand Down
19 changes: 16 additions & 3 deletions lib/byron/src/Cardano/Wallet/Byron/Network.hs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ import Control.Concurrent.Async
import Control.Exception
( IOException )
import Control.Monad
( (>=>) )
( forever, (>=>) )
import Control.Monad.Catch
( Handler (..) )
import Control.Monad.Class.MonadAsync
Expand Down Expand Up @@ -159,6 +159,8 @@ import Ouroboros.Network.Channel
( Channel )
import Ouroboros.Network.Codec
( DeserialiseFailure )
import Ouroboros.Network.CodecCBORTerm
( CodecCBORTerm )
import Ouroboros.Network.Driver.Simple
( TraceSendRecv, runPeer )
import Ouroboros.Network.Mux
Expand Down Expand Up @@ -190,7 +192,7 @@ import Ouroboros.Network.Protocol.ChainSync.Codec
import Ouroboros.Network.Protocol.ChainSync.Type
( ChainSync )
import Ouroboros.Network.Protocol.Handshake.Version
( CodecCBORTerm, DictVersion (..), simpleSingletonVersions )
( DictVersion (..), simpleSingletonVersions )
import Ouroboros.Network.Protocol.LocalTxSubmission.Client
( LocalTxClientStIdle (..)
, LocalTxSubmissionClient (..)
Expand Down Expand Up @@ -425,7 +427,17 @@ mkNetworkClient tr bp chainSyncQ localTxSubmissionQ =
let tr' = contramap MsgTxSubmission tr in
InitiatorProtocolOnly $ MuxPeerRaw $ \channel ->
localTxSubmission tr' localTxSubmissionQ channel
, localStateQueryProtocol =
doNothingProtocol
}
NodeToClientV_2

-- | A protocol client that will never leave the initial state.
doNothingProtocol
:: MonadTimer m => RunMiniProtocol 'InitiatorApp ByteString m a Void
doNothingProtocol =
InitiatorProtocolOnly $ MuxPeerRaw $
const $ forever $ threadDelay 1e6

-- Connect a client to a network, see `mkNetworkClient` to construct a network
-- client interface.
Expand All @@ -440,7 +452,7 @@ connectClient
-> IO ()
connectClient tr handlers client (vData, vCodec) addr = withIOManager $ \iocp -> do
let vDict = DictVersion vCodec
let versions = simpleSingletonVersions NodeToClientV_1 vData vDict client
let versions = simpleSingletonVersions NodeToClientV_2 vData vDict client
let tracers = NetworkConnectTracers
{ nctMuxTracer = nullTracer
, nctHandshakeTracer = contramap MsgHandshakeTracer tr
Expand Down Expand Up @@ -511,6 +523,7 @@ handleMuxError tr onResourceVanished = pure . errorType >=> \case
MuxIngressQueueOverRun -> pure False
MuxInitiatorOnly -> pure False
MuxSDUReadTimeout -> pure False
MuxSDUWriteTimeout -> pure False
MuxIOException e ->
handleIOException tr onResourceVanished e
MuxBearerClosed -> do
Expand Down
2 changes: 1 addition & 1 deletion lib/core/src/Cardano/Wallet/Logging.hs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ trMessage tr = Tracer $ \arg ->
<*> pure (LogMessage arg)

instance forall m a. (MonadIO m, ToText a, HasPrivacyAnnotation a, HasSeverityAnnotation a) => Transformable Text m a where
trTransformer _fmt _verb = Tracer . traceWith . trMessageText
trTransformer _verb = Tracer . traceWith . trMessageText

-- | Tracer transformer which removes tracing below the qgiven severity limit.
filterTraceSeverity
Expand Down
4 changes: 2 additions & 2 deletions nix/.stack.nix/Win32-network.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/byron-spec-chain.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/byron-spec-ledger.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-binary-test.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-binary.nix

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

5 changes: 2 additions & 3 deletions nix/.stack.nix/cardano-crypto-class.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-crypto-test.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-crypto-wrapper.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-ledger-test.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-ledger.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-prelude-test.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-prelude.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/cardano-slotting.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/contra-tracer.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/io-sim-classes.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/io-sim.nix

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

5 changes: 3 additions & 2 deletions nix/.stack.nix/iohk-monitoring.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/lobemo-backend-aggregation.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/lobemo-backend-ekg.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/lobemo-backend-monitoring.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/lobemo-scribe-systemd.nix

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

4 changes: 2 additions & 2 deletions nix/.stack.nix/network-mux.nix

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

Loading

0 comments on commit 30bead7

Please sign in to comment.