Skip to content

Commit a4e23fd

Browse files
committed
Fix 4493 bug - essentially type field in the Shelley era text envelope tx body was being written to disk as "TxWitnessShelley" and being read from disk as "TxWitness Shelley". I.e there was a mismatch and therefore it was not possible to read shelley era transaction bodies.
1 parent 40458ee commit a4e23fd

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Diff for: cardano-api/src/Cardano/Api/Tx.hs

+1-1
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,7 @@ instance IsCardanoEra era => HasTextEnvelope (KeyWitness era) where
439439
textEnvelopeType _ =
440440
case cardanoEra :: CardanoEra era of
441441
ByronEra -> "TxWitnessByron"
442-
ShelleyEra -> "TxWitnessShelley"
442+
ShelleyEra -> "TxWitness ShelleyEra"
443443
AllegraEra -> "TxWitness AllegraEra"
444444
MaryEra -> "TxWitness MaryEra"
445445
AlonzoEra -> "TxWitness AlonzoEra"

Diff for: cardano-cli/src/Cardano/CLI/Shelley/Run/Transaction.hs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1759,7 +1759,7 @@ acceptKeyWitnessCDDLSerialisation err =
17591759
firstExceptT (ShelleyTxCmdTextEnvCddlError tEnvErr)
17601760
$ newExceptT $ readFileTextEnvelopeCddlAnyOf teTypes fp
17611761

1762-
teTypes = [ FromCDDLWitness "TxWitness Shelley" CddlWitness
1762+
teTypes = [ FromCDDLWitness "TxWitness ShelleyEra" CddlWitness
17631763
, FromCDDLWitness "TxWitness AllegraEra" CddlWitness
17641764
, FromCDDLWitness "TxWitness MaryEra" CddlWitness
17651765
, FromCDDLWitness "TxWitness AlonzoEra" CddlWitness

0 commit comments

Comments
 (0)