Description
Internal
Area
Plutus Related to Plutus Scripts (Alonzo).
Summary
Inline datum, reference script and read-only reference are features supported only in Babbage Tx era. When trying to use these in older era transactions (e.g. Allegra), the behavior is inconsistent.
Inline datum:
Attempt to build Alonzo era transaction fails with Error: Inline datums cannot be used for Alonzo era transactions.
Building Mary era transaction succeeds, and inline datum is ignored.
$ cardano-cli transaction build-raw --fee 0 --out-file test_inline_datum_old_tx_era_ci0_ooj_step1_estimate_tx_debug.body --tx-in "b157a77e652f6d9327dd9a6b1499f3ac17d94fb6242ac7ee101ce748ba73138c#0" --tx-out "addr_test1wqag3rt979nep9g2wtdwu8mr4gz6m4kjdpp5zp705km8wys6t2kla+2400250" --tx-out-inline-datum-file /home/martink/Source/repos/cardano-node-tests/cardano_node_tests/tests/data/plutus/typed-42.datum --tx-out "addr_test1vpc3rszvczcyvu492p4z7le5zzyqfslzz79373k3xna6hrcsanpae+2000000" --tx-out "addr_test1vrmgc2xamqfkuzpnxrymlhy8cj8guhvezp3uqv328jm5qlguv296k+2995599750" --alonzo-era
Command failed: transaction build-raw Error: Inline datums cannot be used for Alonzo era transactions.
$ cardano-cli transaction build-raw --fee 0 --out-file test_inline_datum_old_tx_era_ci0_ooj_step1_estimate_tx_debug.body --tx-in "b157a77e652f6d9327dd9a6b1499f3ac17d94fb6242ac7ee101ce748ba73138c#0" --tx-out "addr_test1wqag3rt979nep9g2wtdwu8mr4gz6m4kjdpp5zp705km8wys6t2kla+2400250" --tx-out-inline-datum-file /home/martink/Source/repos/cardano-node-tests/cardano_node_tests/tests/data/plutus/typed-42.datum --tx-out "addr_test1vpc3rszvczcyvu492p4z7le5zzyqfslzz79373k3xna6hrcsanpae+2000000" --tx-out "addr_test1vrmgc2xamqfkuzpnxrymlhy8cj8guhvezp3uqv328jm5qlguv296k+2995599750" --mary-era
Reference script:
Building any old era transaction (transaction era < Babbage) with reference script succeeds and reference script is ignored.
Read-only reference input:
Attempt to build any old era transaction (transaction era < Babbage) with read-only reference input fails with error like
Error: Reference inputs cannot be used for Mary era transactions.
Expected behavior
Attempt to use Babbage features in older era transactions should fail with Error: <feature> cannot be used for <old era name> era transactions
System info (please complete the following information):