Protocol Ithaca

Important: revision PsiThaCaT...jVP of protocol Ithaca contains bugs that have been corrected in the latest version Psithaca2...z6A.

This page contains all the relevant information for protocol Ithaca (see Protocol naming).

The code can be found in the src/proto_012_Psithaca directory of the master branch of Tezos.

This page documents the changes brought by protocol Ithaca with respect to Hangzhou.

New Environment Version (V4)

This protocol requires a different protocol environment than Hangzhou. It requires protocol environment V4, compared to V3 for Hangzhou. (MRs !3379, !3468)

  • Move BLS12-381 to blst backend. (MR !3296)

  • Expose BLS signature module. (MR !3470)

  • Remove Error-monad compat layer. (MR !3575)

  • Allow different type of error categories in the different error monads. (MR !3664)

  • Fix interface of Hex. (MR !3267)

  • Fix use of Micheline canonical encoding. (MR !3764)

  • Add concat_map. (MR !3801)

  • Make Micheline.canonical_location abstract. (MR !3744)

  • Error_monad: better tracing primitives. (MR !3589)

  • Error-monad: simpler trace_eval. (MR !3869)

  • Add missing functions from Lwtreslib. (MR !3905)

  • Expose an order for folding over the context. (MR !3910)

  • List: fix to_seq signature. (MR !3961)

Tenderbake

Precheck of operations

  • Expose precheck_manager and check_manager_signature (MR !3872)

  • Remove the gas block limit for prevalidator mode. (MR !3802)

Michelson

  • A new SUB_MUTEZ instruction has been added, it is similar to the mutez case of the SUB instruction but its return type is option mutez instead of mutez. This allows subtracting mutez values without failing in case of underflow. (MR !3079)

  • The SUB instruction on type mutez is deprecated. It can be replaced by SUB_MUTEZ; ASSERT_SOME (and SUB; DROP can be replaced by ASSERT_CMPGE). (MR !3079)

  • The MAP instruction can now also be applied to values of type option a. In this case the block of code given is executed if and only if the value at the top of the stack is Some a. It should map the value at the top of the stack into a value of any type b. The block has access to the remainder of the stack also, but its type should remain unchanged. The result of the instruction is the stack returned by the applied block of code, where the value at the top is wrapped in Some again. If the value at the top of input stack is None, the instruction does nothing. (MR !3574)

Tickets Hardening (ongoing)

  • Add ticket-balance storage module. (MR !3495)

  • Add API for scanning values for tickets. (MR !3591)

  • Add API for generating ticket-balance key hashes. (MR !3788)

Bug Fixes

  • Use Cache_costs.cache_find in cache find. (MR !3752)

  • Fix gas accounting for the deserialization of Michelson arguments in operations. (MR !3930)

  • Do not count type annotation size. (MR !4075)

Minor Changes

  • Update and simplify fixed constants. (MR !3454)

  • Simplify pack cost. (MR !3620)

  • Do not play with locations inside protocol. (MR !3667)

  • Remove the optional entrypoint in ticketer address. (MR !3570)

  • Make delegate optional for bootstrap contracts. (MR !3584)

  • Fix interface of Hex. (MR !3267)

  • Update migration for protocol “I”. (MR !3668)

  • Make max_operations_ttl a parametric constant of the protocol, now called max_operations_time_to_live. (MR !3709)

  • NOW and LEVEL are now passed to the Michelson interpreter as step constants instead of being read from the context each time these instructions are executed. (MR !3524)

  • The RPC ../helpers/current_level does not support anymore a negative offset argument. The level which used to be returned by ../<block>/helpers/current_level?offset=-<n> can still be obtained by ../<block~n>/helpers/current_level. (MR !3808)

  • Ensure annotations are non-empty. (MR !3746)

  • Only allow positive depth in context query RPC and other RPC. (MR !3564)

  • Liquidity Baking: postpone the sunset level by 819,200 blocks and decrease the escape hatch threshold from one half to one third. (MR !3911)

  • Bump up bls12-381.1.1.0. (MRs !3914, !3942)

  • Refactor empty transactions. (MR !3867)

  • Fix storage error during transfer. (MR !3963)

  • Update gas costs for the new version of bls12-381, and other minor gas changes. (MR !3955)

  • In the michelson_v1.runtime_error error, which appears in the error trace of operations failing because of runtime errors (such as interpreting the FAILWITH instruction) during the execution of a smart contract, the contract_code field is deprecated. The failed script can still be fetched from the address returned in the contract_handle field. (MR !4223)

  • Other internal refactorings or documentation. (MRs !3506, !3550, !3593, !3552, !3588, !3612, !3575, !3622, !3631, !3630, !3707, !3644, !3529, !3739, !3741, !3695, !3763, !3779, !3745, !3256, !3326, !3812, !3920, !3929)

  • Add /chains/main/blocks/<block>/context/selected_snapshot?cycle=<cycle> RPC to retrieve the snapshot index used to compute baking right for the given block’s cycle or at the explicit given ‘cycle’ optional argument. Context entries located in /chains/main/blocks/<block>/context/raw/bytes/cycle/<cycle>/roll_snapshot are no longer accessible after Tenderbake. As observed in issue #2764, the RPC is buggy for cycle 474: the correct result for that cycle is index 16 (not 4).