Skip to content

Commit 7025d78

Browse files
authored
Do not recompute integrity hash (#1619)
This is not needed anymore as we are not converting between Babbage and Conway transactions anymore. Consequently the TODO comment is also not needed as the upgradeTx / conversion was removed. --- * [x] CHANGELOG update not needed * [x] Documentation update not needed * [x] Haddocks update not needed * [x] No new TODOs introduced; removed one Signed-off-by: Sasha Bogicevic <[email protected]>
1 parent d4b3cbc commit 7025d78

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

hydra-node/src/Hydra/Chain/Direct/Wallet.hs

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ import Cardano.Ledger.Core qualified as Core
6363
import Cardano.Ledger.Core qualified as Ledger
6464
import Cardano.Ledger.Crypto (HASH, StandardCrypto)
6565
import Cardano.Ledger.Hashes (EraIndependentTxBody)
66-
import Cardano.Ledger.Plutus.Language (Language (PlutusV2))
6766
import Cardano.Ledger.SafeHash qualified as SafeHash
6867
import Cardano.Ledger.Shelley.API (unUTxO)
6968
import Cardano.Ledger.Shelley.API qualified as Ledger
@@ -94,7 +93,6 @@ import Hydra.Cardano.Api (
9493
fromLedgerUTxO,
9594
getChainPoint,
9695
makeShelleyAddress,
97-
recomputeIntegrityHash,
9896
shelleyAddressInEra,
9997
toLedgerAddr,
10098
toLedgerTx,
@@ -181,11 +179,9 @@ newTinyWallet tracer networkId (vk, sk) queryWalletInfo queryEpochInfo querySome
181179
-- We query pparams here again as it's possible that a hardfork
182180
-- occurred and the pparams changed.
183181
pparams <- querySomePParams
184-
pure $ do
185-
-- TODO: request re-export of upgradeTx in cardano-ledger-api
186-
let conwayTx = toLedgerTx partialTx
187-
coverFee_ pparams systemStart epochInfo ledgerLookupUTxO walletUTxO conwayTx
188-
<&> fromLedgerTx . recomputeIntegrityHash pparams [PlutusV2]
182+
pure $
183+
fromLedgerTx
184+
<$> coverFee_ pparams systemStart epochInfo ledgerLookupUTxO walletUTxO (toLedgerTx partialTx)
189185
, reset = initialize >>= atomically . writeTVar walletInfoVar
190186
, update = \header txs -> do
191187
let point = getChainPoint header

0 commit comments

Comments
 (0)