From 8ba844d4e30b962e0c5f532bc52f9144804482fb Mon Sep 17 00:00:00 2001 From: Pablo Lamela Date: Mon, 20 May 2024 20:34:26 +0200 Subject: [PATCH 1/2] Fix compilation errors --- cabal.project | 7 +++++++ cardano-cli/src/Cardano/CLI/Byron/Run.hs | 4 ++-- cardano-cli/src/Cardano/CLI/Read.hs | 4 ++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/cabal.project b/cabal.project index 85b168e602..2c109bd755 100644 --- a/cabal.project +++ b/cabal.project @@ -19,6 +19,13 @@ index-state: packages: cardano-cli +source-repository-package + type: git + location: https://github.com/IntersectMBO/cardano-api.git + tag: 1244e702287daedbde0cffa320d1eb423493321e + subdir: cardano-api + --sha256: 1wjhyliq3qv83m956mvinshd8cbrkyjlcx97s34qxi9cilskn210 + program-options ghc-options: -Werror diff --git a/cardano-cli/src/Cardano/CLI/Byron/Run.hs b/cardano-cli/src/Cardano/CLI/Byron/Run.hs index 12b9993e01..d97d98713a 100644 --- a/cardano-cli/src/Cardano/CLI/Byron/Run.hs +++ b/cardano-cli/src/Cardano/CLI/Byron/Run.hs @@ -192,7 +192,7 @@ runSpendGenesisUTxO genesisFile nw bKeyFormat (NewTxFile ctTx) ctKey genRichAddr let tx = txSpendGenesisUTxOByronPBFT genesis nw sk genRichAddr outs firstExceptT ByronCmdHelpersError . ensureNewFileLBS ctTx - $ teCddlRawCBOR $ serializeByronTx tx + $ teRawCBOR $ serializeByronTx tx -- Construct a Byron era tx runSpendUTxO @@ -208,4 +208,4 @@ runSpendUTxO nw bKeyFormat (NewTxFile ctTx) ctKey ins outs = do let gTx = txSpendUTxOByronPBFT nw sk ins outs firstExceptT ByronCmdHelpersError . ensureNewFileLBS ctTx - $ teCddlRawCBOR $ serializeByronTx gTx + $ teRawCBOR $ serializeByronTx gTx diff --git a/cardano-cli/src/Cardano/CLI/Read.hs b/cardano-cli/src/Cardano/CLI/Read.hs index d9ba0f0c00..f5056e93ea 100644 --- a/cardano-cli/src/Cardano/CLI/Read.hs +++ b/cardano-cli/src/Cardano/CLI/Read.hs @@ -1026,7 +1026,7 @@ readFileOrPipeTextEnvelopeAnyOf types file = do deserialiseFromTextEnvelopeAnyOf types te readFileOrPipeTextEnvelopeCddlAnyOf - :: [FromSomeTypeCDDL TextEnvelopeCddl b] + :: [FromSomeTypeCDDL TextEnvelope b] -> FileOrPipe -> IO (Either (FileError TextEnvelopeCddlError) b) readFileOrPipeTextEnvelopeCddlAnyOf types file = do @@ -1038,7 +1038,7 @@ readFileOrPipeTextEnvelopeCddlAnyOf types file = do readTextEnvelopeCddlFromFileOrPipe :: FileOrPipe - -> IO (Either (FileError TextEnvelopeCddlError) TextEnvelopeCddl) + -> IO (Either (FileError TextEnvelopeCddlError) TextEnvelope) readTextEnvelopeCddlFromFileOrPipe file = do let path = fileOrPipePath file runExceptT $ do From 0196f48ebc713072bfb6efb74ef204f638456d78 Mon Sep 17 00:00:00 2001 From: Pablo Lamela Date: Tue, 21 May 2024 22:50:59 +0200 Subject: [PATCH 2/2] Fix some tests --- .../cardano-cli-golden/files/golden/shelley/witness-out.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/shelley/witness-out.json b/cardano-cli/test/cardano-cli-golden/files/golden/shelley/witness-out.json index dc72376a87..b068eaec86 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/shelley/witness-out.json +++ b/cardano-cli/test/cardano-cli-golden/files/golden/shelley/witness-out.json @@ -1,5 +1,5 @@ { "type": "TxWitness ShelleyEra", "description": "Key Witness ShelleyEra", - "cborHex": "8258208dc60533b5dfa60a530955a696323a2ef4f14e8bc95a8f84cf6c441fea4234275840a20a2c8b1ffc2151eee3f659fc4076f9859d7d4d073933275470f270128736d231a2fb5e1bc2a6058ef2e58bc98266d192c55d6435ab591ce72cb165a7ec4e03" + "cborHex": "82008258208dc60533b5dfa60a530955a696323a2ef4f14e8bc95a8f84cf6c441fea4234275840a20a2c8b1ffc2151eee3f659fc4076f9859d7d4d073933275470f270128736d231a2fb5e1bc2a6058ef2e58bc98266d192c55d6435ab591ce72cb165a7ec4e03" }