Skip to main content

Ledger Team Update

· 5 min read
Alexey Kuleshevich
Ledger Team Software Engineer

High level summary​

Leios remained the main focus and moved further toward its concrete block and certificate structure. We added the LEIOSCERT rule together with the Leios-certificate-related BBODY failures, defined the EbReferences CDDL and an Annotator decoder for it, and started tracking the last tick slot number in the new epoch state and the last endorser block announcement in the ledger state. We also prevented duplicate BLS keys from being used, improved how Leios committee seats are rendered (hex keys and decimal weights), integrated the week 42 ledger changes on the prototype branch, and backed the work with Leios certificate golden tests and better example parameters.

A significant milestone was the Dijkstra era gaining its economic machinery: we implemented the minFee calculation for Dijkstra, adopted the CIP-23 effective cost and margin in the rewards calculations, and fixed the block body size computation. There was also a cluster of serialisation and decoder fixes, covering the PlutusData decoder, redeemers for protocol version 12, NonEmpty set and map decoders, and the IPv4 encoding order (now network order rather than swapped), with property tests added for Plutus data conversion.

Work on sub-transactions continued, with min-ada validation switched to a non-static check and submitTx in the ImpTests now randomly exercising top-level and sub-level transactions, alongside new Imp tests for SUBDELEG, SUBPOOL and SUBGOVCERT. On the rules side we added LEDGER rule limits and stopped inverting predicate failures in the small-steps framework, and we simplified transaction hashing by removing hashTx and the DijkstraEraTx type class in favour of the existing HashAnnotated. We also added a queryStakePoolState ledger state query.

On the testing and releasing side we enabled ExUnits tests and fixed the bootstrap witness in conformance, made the Plutus tests run with arbitrary Plutus versions, added tests for transValidityInterval and for the ValidityInterval/VotingProcedures semigroup and monoid instances, tested voting stake computation for pools with zero delegations, updated the formal ledger specification, and filled in a few missing predicate-check ImpTests. Infrastructure changes were limited to a cleret bump to 0.5.2.1 and a dependency update.

Low level summary​

Features​

  • PR-6162 - Add queryStakePoolState
  • PR-6188 - Switch sub-transaction min-ada validation to be a non-static check
  • PR-6189 - Fix decoder for PlutusData
  • PR-6187 - Fix IPv4 encoding order to use network order instead of swapped
  • PR-6193 - Leios prototype: Integrate ledger changes for w42
  • PR-6165 - Prevent duplicate BlsKey from being used
  • PR-6195 - Remove hashTx and DijkstraEraTx in favor of HashAnnotated
  • PR-6184 - Add last tick slot number to NES and last EB announcement to LS
  • PR-6202 - Add Leios certificate related BBODY failures
  • PR-6210 - EbReferences CDDL
  • PR-6190 - Implement minFee calculation for Dijkstra
  • PR-6197 - Use CIP-23 effective cost and margin in rewards calculations
  • PR-6208 - Stop inverting predicate failures in small-steps
  • PR-6201 - Render Leios committee seats as hex keys and decimal weights
  • PR-6219 - Add an Annotator decoder for EbReferences
  • PR-6224 - Fix redeemers for PV12
  • PR-6225 - Fix block body size computation in Dijkstra
  • PR-6209 - Add LEIOSCERT
  • PR-6221 - LEDGER rule limits
  • PR-6230 - Some decoder fixes for NonEmpty Sets and Maps

Testing​

  • PR-6160 - Make submitTx randomly submit top-level and sub-level transactions in ImpTests
  • PR-6192 - Fix bootstrap witness in conformance
  • PR-6169 - Make plutus tests run with arbitrary Plutus versions
  • PR-6163 - Tests for Semigroup and Monoid instances for ValidityInterval and VotingProcedures
  • PR-6200 - Enable exunits tests in conformance
  • PR-6183 - Add tests for transValidityInterval
  • PR-6011 - Add leios cert golden tests
  • PR-6194 - Set better Leios example parameters
  • PR-6103 - Test voting stake computation for pools with zero delegations
  • PR-6218 - Add property tests for Plutus Data conversion
  • PR-6223 - Fix generator for script hash integrity tests
  • PR-6059 - Add Imp tests for SUBDELEG, SUBPOOL and SUBGOVCERT
  • PR-6228 - Update formal ledger specification
  • PR-6232 - Add missing ImpTests for some predicate checks

Infrastructure and releasing​

  • PR-6220 - Bump certifi from 2025.1.31 to 2026.10.19 in /doc
  • PR-6231 - Update cleret to 0.5.2.1

Mithril Team Update

· 2 min read
Jean-Philippe Raynaud
Mithril Tech Lead

High level overview​

This week, the Mithril team defined the progressive rollout strategy of the IPFS distribution, documented the replication of the immutable archives with a Kubo node, and created the new mithril-setup crate. They also addressed the findings of the M1.1 and M1.2 milestone audits.

The team kept working on the deterministic resolution of the SNARK verification key collisions in the key registration, the activation of the snark feature by default, the implementation of a ratio for IPFS downloads in the client, and the prototype of the orchestrator of the setup command.

Finally, they fixed the blocks and transactions verification failure on the testing-preview network, cleaned the mithril-test-lab directory, fixed the dependencies with security advisories, and worked on the upgrade to Cardano node 11.2.

Low level overview​

Features​

  • Completed the issue Define the progressive rollout strategy of the IPFS distribution #3607
  • Completed the issue Document the replication of the immutable archives with a Kubo node #3625
  • Completed the issue Create a new mithril-setup crate #3616
  • Completed the issue Address the findings of the M1.1 milestone audit #3635
  • Completed the issue Address the findings of the M1.2 milestone audit #3646
  • Worked on the issue Resolve SNARK verification key collisions deterministically in the key registration #3591
  • Worked on the issue Activate snark feature by default #3573
  • Worked on the issue Implement a ratio for IPFS downloads in the client #3641
  • Worked on the issue Prototype the orchestrator of the mithril-setup command #3642

Protocol maintenance​

  • Completed the issue Blocks and transaction verification fails on testing-preview #3526
  • Completed the issue Clean the mithril-test-lab directory #3595
  • Completed the issue Fix the dependencies with security advisories reported by the weekly check #3649
  • Worked on the issue Upgrade to Cardano 11.2 #3585

Mithril Team Update

· 3 min read
Jean-Philippe Raynaud
Mithril Tech Lead

High level overview​

This week, the Mithril team released the 2642 distribution. This version reads the protocol configuration from the Cardano chain in the signer and the aggregator, supports the Cardano node 11.1.3 and the DMQ node 0.7.2.0, and removes the support for the Gzip compressed snapshot archives. It also introduces a certificate chain cache in the client, support for compact SNARK certificates with a genesis-signed registry of the trusted circuit verification keys, and preliminary support for IPFS as a storage location of the immutable files (all unstable). It includes various bug fixes and improvements as well.

The team also published the immutable archives directory of the aggregator under an IPNS name, and selected a crate for the user interaction of the setup command. They kept working on the deterministic resolution of the SNARK verification key collisions in the key registration, the progressive rollout strategy of the IPFS distribution, the new mithril-setup crate, and the findings of the M1.1 milestone audit.

Finally, they worked on the upgrade to Cardano node 11.2, the renaming of DeprecatedCommand to RemovedCommand in the client CLI, the cleanup of the mithril-test-lab directory, and the investigation of the blocks and transactions verification failure on the testing-preview network.

Low level overview​

Features​

  • Completed the issue Publish the immutable archives directory under an IPNS name in the aggregator #3606
  • Completed the issue Identify a crate to use for the user interaction (TUI) of the setup command #3618
  • Worked on the issue Resolve SNARK verification key collisions deterministically in the key registration #3591
  • Worked on the issue Define the progressive rollout strategy of the IPFS distribution #3607
  • Worked on the issue Create a new mithril-setup crate #3616
  • Worked on the issue Address the findings of the M1.1 milestone audit #3635

Protocol maintenance​

Plutus Core Team Update

· 2 min read
Ziyang Liu
Software Engineering Lead

High level summary​

The Plutus team has enabled multiIndexArray (CIP-0156) and the new Value builtins policies, assetCount, keepPolicies and dropPolicies (CIP-0168) at Dijkstra for all Plutus ledger language versions. These require the Dijkstra hard fork before they can be used on-chain. We've also added conformance tests for multiIndexArray, brought the specification's versioning section up-to-date, and added casing on Data to the Agda metatheory.

The guardrail script now supports optional parameters that governance proposals can set or unset, and the Plinth compiler can report timings for individual compilation stages. Work in progress includes generating Agda typechecking tests from conformance tests, and CEK machine optimizations.

Key Pull Requests Merged​

Pull Requests In Progress​

Consensus Team Update

· 5 min read
Damian Nadales
Consensus Team Lead

High level summary​

  • Leios implementation on main (Treasury Funding Initiative 4: Ouroboros Leios Implementation):
    • Merged the Praos2 protocol into main. Praos2 is Praos plus the Leios overlay. One definition, PolyPraos, now has all the Praos rules, and both Praos and Praos2 are variants of it. When a later Praos variant comes, it will extend PolyPraos instead of adding a new protocol next to it (#2386). A follow-up fixes the translation of the LedgerView from Conway to Dijkstra, a defect that #2386 kept from the old code (#2399).
    • An Endorser Block can no longer get its certificate in a later era or a later epoch than the block that announced it. The era rule avoids open design questions about a block that crosses an era boundary. The epoch rule keeps the interface between consensus and the ledger simpler (#2409).
    • Moved the LeiosNotify clients from the leios-prototype branch to main. A client disconnects from a peer that sends a message that an honest node would not send. A new test suite runs the real node against peers that can send any message (#2403).
    • Moved the LeiosFetch servers from the leios-prototype branch to main (#2416). The next step is the logic that decides which Endorser Blocks to fetch, and the clients that fetch them.
    • Fixed a defect in the LeiosDB garbage collection. If an exception stopped a collection pass, the rows that the pass marked for deletion stayed in the database. The next pass now finds and deletes them (#2401).
    • The Leios design document now has a detailed section on Endorser Block diffusion. It gives the plan that came out of the LeiosFetch design work, and how the node keeps its memory use bounded (ouroboros-leios#1005).
  • Leios prototype development (Treasury Funding Initiative 4: Ouroboros Leios Implementation):
    • Merged a large change that makes Endorser Block diffusion in the prototype close to the production design (#2282). Some examples:
      • The node fetches an Endorser Block only when an election or a certificate justifies it, never because a peer offers it.
      • A peer can offer only an Endorser Block that it announced, and each part only once. If a peer breaks a rule, the node disconnects from it.
      • If an announcement gives the wrong size for an Endorser Block, the node does not relay that block and does not vote for it.
      • The node checks the certificate in a ranking block when the block arrives, before chain selection.
    • Before #2282, the prototype used the Leios header format in all eras. It now uses the Leios format from Dijkstra only, and the unchanged Praos format before. The testnet starts before Dijkstra, so we must restart its chain from genesis, and every node must update.
    • LeiosNotify has two new messages, MsgQuit and MsgCanceled, so the node can stop a session while it waits for a reply. Before, this was not possible. So when the peer governor moved a peer from hot to warm, the node closed the whole connection (#2344).
    • Backported the epoch rule from #2409 to the prototype (#2415).
  • Maintenance and support (Treasury Funding Initiative 17: Maintenance and Support):
    • Released ouroboros-consensus 5.1.0.1. The tool db-truncater has a new flag, --leios. Without the flag, the tool does not need the LeiosDB files and does not change them (#2393).
    • Tracing now shows the Dijkstra ledger predicate failures. Before, the log formatting for these failures called error, so a Dijkstra block that failed validation crashed the thread that wrote the trace (#2406, ported to main in #2407).
    • Added the local state query GetStakePoolState, which the ledger defines in cardano-ledger#6162 (#2412, for #2405).
    • Added golden tests for the ledger queries. They catch a change to the encoding of a query or its result, which would break client tools. Queries that the ledger already defines, such as NonMyopicMemberRewards, now come from the ledger (#2348).
    • A ledger snapshot now has one version number at the top level, instead of one number for each part. New tests check the golden snapshot files against the CDDL specification, which catches an encoding that does not match the specification. This change also fixes the Peras CDDL (#2395).
    • db-synthesizer now uses the forge function and the mempool of the node, instead of its own copy of the forging logic. One visible change: every slot leader now forges a block, so the synthesized chain can have forks (#2284).