Skip to content

Commit 25a5483

Browse files
cardano-api: 10.8
1 parent 8072ca5 commit 25a5483

File tree

12 files changed

+284
-396
lines changed

12 files changed

+284
-396
lines changed

flake.lock

+47-47
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

hydra-cardano-api/hydra-cardano-api.cabal

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ library
7878
, aeson >=2
7979
, base >=4.16
8080
, bytestring
81-
, cardano-api ^>=10.6
81+
, cardano-api ^>=10.8
8282
, cardano-api:gen
8383
, cardano-binary
8484
, cardano-crypto-class

hydra-cardano-api/src/Hydra/Cardano/Api.hs

-6
Original file line numberDiff line numberDiff line change
@@ -360,12 +360,6 @@ pattern TxAuxScripts{txAuxScripts'} <-
360360
-- ** TxBody
361361

362362
type TxBody = Cardano.Api.TxBody Era
363-
{-# COMPLETE TxBody #-}
364-
365-
pattern TxBody :: TxBodyContent ViewTx -> TxBody
366-
pattern TxBody{txBodyContent} <-
367-
Cardano.Api.TxBody txBodyContent
368-
{-# COMPLETE TxBody #-}
369363

370364
createAndValidateTransactionBody :: TxBodyContent BuildTx -> Either TxBodyError TxBody
371365
createAndValidateTransactionBody = Cardano.Api.createTransactionBody shelleyBasedEra

hydra-cardano-api/src/Hydra/Cardano/Api/Pretty.hs

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ renderTxWithUTxO utxo (Tx body _wits) =
4848
where
4949
Api.ShelleyTxBody _lbody scripts scriptsData _auxData _validity = body
5050
outs = txOuts content
51-
TxBody content = body
51+
content = getTxBodyContent body
5252

5353
inputLines =
5454
"== INPUTS (" <> show (length (txIns content)) <> ")"

hydra-cardano-api/src/Hydra/Cardano/Api/Tx.hs

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ utxoProducedByTx tx =
5656
zip [0 ..] (txOuts body)
5757
<&> bimap (mkTxIn tx) toCtxUTxOTxOut
5858
where
59-
TxBody body = getTxBody tx
59+
body = getTxBodyContent $ getTxBody tx
6060

6161
-- * Type Conversions
6262

hydra-cardano-api/src/Hydra/Cardano/Api/TxIn.hs

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ withWitness txIn =
2727

2828
-- | Access inputs of a transaction, as an ordered list.
2929
txIns' :: Tx era -> [TxIn]
30-
txIns' (getTxBody -> txBody) =
31-
let TxBody TxBodyContent{txIns} = txBody
30+
txIns' (getTxBodyContent . getTxBody -> txBodyContent) =
31+
let TxBodyContent{txIns} = txBodyContent
3232
in fst <$> txIns
3333

3434
-- | Access inputs of a transaction, as an ordered set.

hydra-cardano-api/src/Hydra/Cardano/Api/TxOut.hs

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ import PlutusLedgerApi.V3 qualified as Plutus
2020
-- * Extras
2121

2222
txOuts' :: Tx era -> [TxOut CtxTx era]
23-
txOuts' (getTxBody -> txBody) =
24-
let TxBody TxBodyContent{txOuts} = txBody
23+
txOuts' (getTxBodyContent . getTxBody -> txBody) =
24+
let TxBodyContent{txOuts} = txBody
2525
in txOuts
2626

2727
-- | Modify a 'TxOut' to set the minimum ada on the value.

0 commit comments

Comments
 (0)