fix: keep SealedTx decoding within supported era
Home /
Cardano Foundation /
cardano-wallet
Apr 19, 4-5 AM (0)
Apr 19, 5-6 AM (0)
Apr 19, 6-7 AM (0)
Apr 19, 7-8 AM (0)
Apr 19, 8-9 AM (0)
Apr 19, 9-10 AM (0)
Apr 19, 10-11 AM (0)
Apr 19, 11-12 PM (0)
Apr 19, 12-1 PM (0)
Apr 19, 1-2 PM (0)
Apr 19, 2-3 PM (0)
Apr 19, 3-4 PM (0)
Apr 19, 4-5 PM (0)
Apr 19, 5-6 PM (0)
Apr 19, 6-7 PM (0)
Apr 19, 7-8 PM (0)
Apr 19, 8-9 PM (0)
Apr 19, 9-10 PM (0)
Apr 19, 10-11 PM (0)
Apr 19, 11-12 AM (0)
Apr 20, 12-1 AM (0)
Apr 20, 1-2 AM (0)
Apr 20, 2-3 AM (0)
Apr 20, 3-4 AM (0)
Apr 20, 4-5 AM (0)
Apr 20, 5-6 AM (0)
Apr 20, 6-7 AM (0)
Apr 20, 7-8 AM (0)
Apr 20, 8-9 AM (2)
Apr 20, 9-10 AM (1)
Apr 20, 10-11 AM (0)
Apr 20, 11-12 PM (0)
Apr 20, 12-1 PM (0)
Apr 20, 1-2 PM (0)
Apr 20, 2-3 PM (4)
Apr 20, 3-4 PM (0)
Apr 20, 4-5 PM (1)
Apr 20, 5-6 PM (4)
Apr 20, 6-7 PM (0)
Apr 20, 7-8 PM (0)
Apr 20, 8-9 PM (0)
Apr 20, 9-10 PM (0)
Apr 20, 10-11 PM (0)
Apr 20, 11-12 AM (0)
Apr 21, 12-1 AM (0)
Apr 21, 1-2 AM (0)
Apr 21, 2-3 AM (0)
Apr 21, 3-4 AM (0)
Apr 21, 4-5 AM (0)
Apr 21, 5-6 AM (0)
Apr 21, 6-7 AM (0)
Apr 21, 7-8 AM (0)
Apr 21, 8-9 AM (0)
Apr 21, 9-10 AM (5)
Apr 21, 10-11 AM (9)
Apr 21, 11-12 PM (5)
Apr 21, 12-1 PM (0)
Apr 21, 1-2 PM (5)
Apr 21, 2-3 PM (0)
Apr 21, 3-4 PM (5)
Apr 21, 4-5 PM (0)
Apr 21, 5-6 PM (0)
Apr 21, 6-7 PM (0)
Apr 21, 7-8 PM (0)
Apr 21, 8-9 PM (0)
Apr 21, 9-10 PM (0)
Apr 21, 10-11 PM (0)
Apr 21, 11-12 AM (0)
Apr 22, 12-1 AM (0)
Apr 22, 1-2 AM (0)
Apr 22, 2-3 AM (0)
Apr 22, 3-4 AM (0)
Apr 22, 4-5 AM (0)
Apr 22, 5-6 AM (0)
Apr 22, 6-7 AM (0)
Apr 22, 7-8 AM (0)
Apr 22, 8-9 AM (0)
Apr 22, 9-10 AM (0)
Apr 22, 10-11 AM (0)
Apr 22, 11-12 PM (0)
Apr 22, 12-1 PM (0)
Apr 22, 1-2 PM (0)
Apr 22, 2-3 PM (0)
Apr 22, 3-4 PM (0)
Apr 22, 4-5 PM (0)
Apr 22, 5-6 PM (0)
Apr 22, 6-7 PM (0)
Apr 22, 7-8 PM (0)
Apr 22, 8-9 PM (0)
Apr 22, 9-10 PM (0)
Apr 22, 10-11 PM (0)
Apr 22, 11-12 AM (0)
Apr 23, 12-1 AM (0)
Apr 23, 1-2 AM (0)
Apr 23, 2-3 AM (0)
Apr 23, 3-4 AM (4)
Apr 23, 4-5 AM (0)
Apr 23, 5-6 AM (0)
Apr 23, 6-7 AM (0)
Apr 23, 7-8 AM (0)
Apr 23, 8-9 AM (3)
Apr 23, 9-10 AM (1)
Apr 23, 10-11 AM (0)
Apr 23, 11-12 PM (0)
Apr 23, 12-1 PM (19)
Apr 23, 1-2 PM (5)
Apr 23, 2-3 PM (14)
Apr 23, 3-4 PM (0)
Apr 23, 4-5 PM (0)
Apr 23, 5-6 PM (0)
Apr 23, 6-7 PM (0)
Apr 23, 7-8 PM (0)
Apr 23, 8-9 PM (0)
Apr 23, 9-10 PM (0)
Apr 23, 10-11 PM (0)
Apr 23, 11-12 AM (0)
Apr 24, 12-1 AM (0)
Apr 24, 1-2 AM (0)
Apr 24, 2-3 AM (0)
Apr 24, 3-4 AM (0)
Apr 24, 4-5 AM (0)
Apr 24, 5-6 AM (0)
Apr 24, 6-7 AM (0)
Apr 24, 7-8 AM (1)
Apr 24, 8-9 AM (0)
Apr 24, 9-10 AM (2)
Apr 24, 10-11 AM (0)
Apr 24, 11-12 PM (1)
Apr 24, 12-1 PM (0)
Apr 24, 1-2 PM (0)
Apr 24, 2-3 PM (0)
Apr 24, 3-4 PM (0)
Apr 24, 4-5 PM (1)
Apr 24, 5-6 PM (0)
Apr 24, 6-7 PM (0)
Apr 24, 7-8 PM (0)
Apr 24, 8-9 PM (0)
Apr 24, 9-10 PM (0)
Apr 24, 10-11 PM (0)
Apr 24, 11-12 AM (0)
Apr 25, 12-1 AM (0)
Apr 25, 1-2 AM (0)
Apr 25, 2-3 AM (4)
Apr 25, 3-4 AM (0)
Apr 25, 4-5 AM (0)
Apr 25, 5-6 AM (0)
Apr 25, 6-7 AM (0)
Apr 25, 7-8 AM (0)
Apr 25, 8-9 AM (0)
Apr 25, 9-10 AM (15)
Apr 25, 10-11 AM (0)
Apr 25, 11-12 PM (1)
Apr 25, 12-1 PM (0)
Apr 25, 1-2 PM (0)
Apr 25, 2-3 PM (0)
Apr 25, 3-4 PM (0)
Apr 25, 4-5 PM (0)
Apr 25, 5-6 PM (0)
Apr 25, 6-7 PM (0)
Apr 25, 7-8 PM (0)
Apr 25, 8-9 PM (0)
Apr 25, 9-10 PM (0)
Apr 25, 10-11 PM (0)
Apr 25, 11-12 AM (0)
Apr 26, 12-1 AM (0)
Apr 26, 1-2 AM (0)
Apr 26, 2-3 AM (0)
Apr 26, 3-4 AM (0)
Apr 26, 4-5 AM (0)
112 commits this week
Apr 19, 2026
-
Apr 26, 2026
refactor: remove SealedTx cardano-api surface
docs: plan for finishing SealedTx cardano-api decommission
Enumerates every remaining caller of the deprecated surface after
#5271: production (Cardano.Wallet.hs, Server.hs), old tx builder
(Shelley/Transaction.hs, partially overlaps with #5243), integration
tests (Shared/Transactions.hs, addRequiredSigners in TransactionsNew)
and unit tests (TransactionSpec, TransactionLedgerSpec).
Organises the work into three phases:
A. reachable without #5243 (4 sites)
B. unit-test migration (~20 sites, two files)
C. delete the bridge functions and the three Cardano.Api*
imports in SealedTx.hs
refactor: migrate buildAndSignTransactionPure to ledger-native seal
The signedTx wrapping in Cardano.Wallet went through toCardanoApiTx -> inAnyCardanoEra -> sealedTxFromCardano purely to smuggle the already-ledger tx back through cardano-api. Use the existing ledger-native sealWriteTx from Transaction.Ledger instead (now exported). Drops the two cardano-api bridges inAnyCardanoEra and sealedTxFromCardano from this module. Also refresh the sealWriteTx haddock (the function has been ledger- native since the last revamp; the stale comment claimed otherwise).
refactor: port metadata extraction in Shared/Transactions to ledger-native
Mirror the TransactionsNew.hs:getMetadataFromTx port: project metadata directly from Read.Tx era via Meta.getMetadata . Meta.getEraMetadata instead of round-tripping through cardano-api. Drops the two callers of cardanoTxIdeallyNoLaterThan in this file and the Cardano.Api / ApiEra qualified imports.
refactor: drop dead cardano-api body in addRequiredSigners
The function has been an ADP-3077 TODO stub (error "...") for a long time; the commented-out cardano-api body still referenced getSealedTxBody and sealedTxFromCardanoBody, which blocks their removal. Drop the dead block and note that a future implementation should operate on Read.Tx era via reqSignerHashesTxBodyL.
refactor: drop local sealWriteTx cardano-api bridge in Server.hs
Server.hs carried a local copy of sealWriteTx that re-entered cardano-api (toCardanoApiTx + sealedTxFromCardano) to wrap an already ledger-native balanceTx result. Import the ledger-native sealWriteTx from Transaction.Ledger instead; the local helper goes away. Two call sites now pass Write.recentEra explicitly. Drops the cardano-api bridges cardanoEraFromRecentEra, toCardanoApiTx and W.sealedTxFromCardano from this module's imports.
refactor: migrate _postSealedTx to ledger-native GenTx via EraValue Read.Tx
Replace the cardano-api path (SealedTx → unsealShelleyTx → TxInMode → toConsensusGenTx → GenTx) with a direct ledger-native path (SealedTx → unsafeReadTx :: EraValue Read.Tx → consensusGenTxFromTxRecent → GenTx). The stored 'EraValue Read.Tx' already knows its era, so the separate 'readCurrentEra' query is no longer needed, and 'TxInMode' / 'toConsensusGenTx' / 'unsealShelleyTx' / 'UnsealException' all become unused. Deletes: - Cardano.Wallet.Primitive.Ledger.Shelley.unsealShelleyTx - Cardano.Wallet.Primitive.Ledger.Shelley.UnsealException - cardano-api 'TxInMode' import in primitive - cardano-api 'toConsensusGenTx' import in network-layer Adds 'unsafeReadTx' to the re-export of 'SealedTx' in Cardano.Wallet.Primitive.Types.Tx. Step 1 of SealedTx decommission plan. One fewer caller of 'cardanoTxIdeallyNoLaterThan'; the submission path no longer touches cardano-api.
feat: add sealedTxWitnessCount (ledger-native) and migrate Server.hs
Introduce sealedTxWitnessCount :: SealedTx -> Int, counting VKey plus bootstrap witnesses via 'addrTxWitsL'/'bootAddrTxWitsL' on the stored 'EraValue Read.Tx'. Byron txs counted as 0 (wallet doesn't construct them through SealedTx). Migrate Server.hs's two 'length $ getSealedTxWitnesses sealedTx' sites (redeemer and witness accounting) to use it. Drops 'getSealedTxWitnesses' from Server.hs's import list. Step 2b of SealedTx decommission plan.
feat: port getMetadataFromTx in TransactionsNew to ledger-native
Replace cardano-api round-trip with direct Read.Tx era projection via Meta.getMetadata . Meta.getEraMetadata. Drops the four callers of cardanoTxIdeallyNoLaterThan in this file (the cardano-api re-decode was only used to feed getTxBody/txMetadata). No behavioural change: the ledger metadata path is what Server.hs and DB.TransactionInfo already use.
refactor: delete cardanoTxInExactEra (no remaining callers)
Following the migration of parsePartialTx to deserializeTx, cardanoTxInExactEra has no external callers. Remove it along with the now-redundant Data.Data import in SealedTx.hs.
refactor: use ledger-native deserialisation in parsePartialTx
Replace cardanoTxInExactEra (cardano-api path) with deserializeTx (ledger-native) in the redeemer-bearing partial tx parser. Pattern-matches on RecentEra era so the era singleton witnesses the target ledger type. One fewer caller of cardano-api's 'deserialiseFromCBOR / InAnyCardanoEra Cardano.Tx' path. 'fromCardanoApiTx' → direct use of 'Read.Tx era' unwrapped into 'Write.Tx era'.
feat: add sealedTxFromLedgerTx and migrate sealWriteTx off cardano-api
Introduce sealedTxFromLedgerTx :: Read.IsEra era => Read.Tx era -> SealedTx. Serialises via Read.serializeTx (ledger-native) and wraps in EraValue without any cardano-api involvement. Migrate sealWriteTx in Transaction.Ledger.hs to use the new constructor, pattern-matching on RecentEra to witness the era. Removes the toCardanoApiTx -> sealedTxFromCardano' roundtrip, dropping the Cardano.Api.Extra import from that module. Step 2a of SealedTx decommission plan.
docs: plan for decommissioning SealedTx cardano-api surface
Five-step plan to remove the three remaining Cardano.Api imports from lib/primitive/lib/Cardano/Wallet/Primitive/Types/Tx/SealedTx.hs by eliminating the bridge functions (cardanoTxIdeallyNoLaterThan, cardanoTxInExactEra, sealedTxFromCardano*, getSealedTxBody, getSealedTxWitnesses, cardanoApiTxToReadTx).
refactor(test): compare SealedTx by raw CBOR bytes in TransactionLedgerSpec
Replace compareOnCBOR's roundtrip through cardano-api (cardanoTx → Cardano.serialiseToCBOR) with the raw bytes already stored in SealedTx.serialisedTx. Identical comparison outcome, one fewer caller of cardanoTxIdeallyNoLaterThan. Step 1 of SealedTx decommission plan.
fix: adapt singleton network conversion
Update wallet version in swagger.yaml
Update cardano-wallet version in README.md
Update cardano-wallet version in run/common/docker/run.sh
Update cardano-wallet version in *.cabal files
docs: plan for finishing SealedTx cardano-api decommission
Enumerates every remaining caller of the deprecated surface after
#5271: production (Cardano.Wallet.hs, Server.hs), old tx builder
(Shelley/Transaction.hs, partially overlaps with #5243), integration
tests (Shared/Transactions.hs, addRequiredSigners in TransactionsNew)
and unit tests (TransactionSpec, TransactionLedgerSpec).
Organises the work into three phases:
A. reachable without #5243 (4 sites)
B. unit-test migration (~20 sites, two files)
C. delete the bridge functions and the three Cardano.Api*
imports in SealedTx.hs
feat: add sealedTxFromLedgerTx and migrate sealWriteTx off cardano-api
Introduce sealedTxFromLedgerTx :: Read.IsEra era => Read.Tx era -> SealedTx. Serialises via Read.serializeTx (ledger-native) and wraps in EraValue without any cardano-api involvement. Migrate sealWriteTx in Transaction.Ledger.hs to use the new constructor, pattern-matching on RecentEra to witness the era. Removes the toCardanoApiTx -> sealedTxFromCardano' roundtrip, dropping the Cardano.Api.Extra import from that module. Step 2a of SealedTx decommission plan.
refactor: delete cardanoTxInExactEra (no remaining callers)
Following the migration of parsePartialTx to deserializeTx, cardanoTxInExactEra has no external callers. Remove it along with the now-redundant Data.Data import in SealedTx.hs.
refactor: use ledger-native deserialisation in parsePartialTx
Replace cardanoTxInExactEra (cardano-api path) with deserializeTx (ledger-native) in the redeemer-bearing partial tx parser. Pattern-matches on RecentEra era so the era singleton witnesses the target ledger type. One fewer caller of cardano-api's 'deserialiseFromCBOR / InAnyCardanoEra Cardano.Tx' path. 'fromCardanoApiTx' → direct use of 'Read.Tx era' unwrapped into 'Write.Tx era'.
refactor: migrate _postSealedTx to ledger-native GenTx via EraValue Read.Tx
Replace the cardano-api path (SealedTx → unsealShelleyTx → TxInMode → toConsensusGenTx → GenTx) with a direct ledger-native path (SealedTx → unsafeReadTx :: EraValue Read.Tx → consensusGenTxFromTxRecent → GenTx). The stored 'EraValue Read.Tx' already knows its era, so the separate 'readCurrentEra' query is no longer needed, and 'TxInMode' / 'toConsensusGenTx' / 'unsealShelleyTx' / 'UnsealException' all become unused. Deletes: - Cardano.Wallet.Primitive.Ledger.Shelley.unsealShelleyTx - Cardano.Wallet.Primitive.Ledger.Shelley.UnsealException - cardano-api 'TxInMode' import in primitive - cardano-api 'toConsensusGenTx' import in network-layer Adds 'unsafeReadTx' to the re-export of 'SealedTx' in Cardano.Wallet.Primitive.Types.Tx. Step 1 of SealedTx decommission plan. One fewer caller of 'cardanoTxIdeallyNoLaterThan'; the submission path no longer touches cardano-api.