Skip to main content

19 posts tagged with "ledger"

View All Tags

· 2 min read
Jared Corduan

High level summary

The ledger team made progress on the conway ledger era. In particular, the design and implementation of the new certificates is near complete, we refactored some of our data structures to be able to support DReps, we cleaned up the serialization format, and renamed things to make clearer the differences with Shelley.

The team also completed integration work for the next node release, namely 8.1.0. And, as always, we continue to address technical debt.

Low level summary

Conway progress

  • pull-3408 - Improve conway delegation certificates
  • pull-3428 - Get rid of Constitutional in favor of Genesis and Committee
  • pull-3426 - Add DRep to internal data struture (UMap)
  • pull-3425 - Improve witness logic needed for conway
  • pull-3423 - Rename ShelleyDelegCerts constructors to distinguish them from Conway
  • pull-3421 - Rename DCert -> TxCert
  • pull-3454 - conway CDDL minor fixes

Improve testing

  • pull-3403 - Add Plutus script context golden tests

Integration work

  • pull-3410 - Update chaps index
  • pull-3416 - Bump cardano-ledger-alonzo-test version
  • pull-3414 - Bump cardano-ledger-shelley-test minor version
  • pull-3420 - Bump cardano-ledger-shelley-ma-test version
  • pull-3441 - Release cardano-ledger-[alonzo|babbage]-1.2.1

Technical debt

  • pull-3409 - Unit test - no such thing as a reference datum
  • pull-3407 - Fixup release process documentation
  • pull-3404 - Create TotalDeposits events during all eras
  • pull-3402 - Fix broken references in the Shelley spec
  • pull-3424 - Remove no longer used cardano-ledger-shelley-ma package
  • pull-3432 - Add an example on how to bump up versions in the changelog
  • pull-3440 - Revert back to the group serialization for ProtVer for PParams

· 2 min read
Jared Corduan

High level summary

The ledger team focused mainly on the conway ledger era and node integration. For conway, we completed a large structural change that now allows for delegation certificates to be parameterized by era, and introducing new certificates for the first time since Shelley. We also continue to build out our contraint based generators that we will use to property test the conway era. In particular, we can now generate an entire ledger state and a transaction which is balanced with respect to the ledger state.

Low level summary

Conway certificates

Certificiates are now abstracted as a type family in the ledger codebase. Moreover, there are new certificates in the Conway era to support CIP-1694, and MIR certificates have been removed.

Constraint based testing

Our plan for property testing in the conway era is to no longer use the trace generators, but instead generate ledger states and transactions based on constraints. We hit a milestone this week, namely the ability to generate a balanced transaction in the context of a ledger state, all based on our ever growing constaint language.

Integration work

Technical debt

· One min read
Jared Corduan

High level summary

We continued to make progress on CIP-1694 and the conway ledger era. In particular, the conway era now supports Plutus V3. Finally, we made small improvements to the ledger API and now host our Haskell code documentation (haddocks) on github pages.

Low level summary

Conway ledger era

Haddocks hosted on github pages

Small improvements to the API

Technical Debt

  • [pull-3367] Fix cost model json instances.
  • [pull-3371] UMap cleanup.
  • [pull-3373] Upgrade to ghc 9.2.7 and cabal 3.10.1.
  • [pull-3375] Sadly, we had to revert the TICKF optimizations. There was a regression we do not yet understand.
  • [pull-3377] Fix cabal warnings.
  • [pull-3383] Fix multi-asset test.

· 2 min read
Kevin Hammond

Incident reporting: Cardano block production temporary outage

On Sunday, January 22, 2023, an incident occurred resulting in block production pausing for a brief period of time (approximately two minutes, similar to the usual pause at an epoch boundary). Around 50% of block-producing nodes and relays restarted during this period. Having restarted, nodes continued to produce blocks without failure. While the network continued to operate, the issue did have the potential to affect network integrity, so was flagged as a ‘critical’ incident, thus warranting immediate response and investigation by IOG engineers. The investigation (with SPO & Cardano Foundation collaboration) quickly revealed the cause of the issue – a complex bug in data structure handling code related to the precise order of insertion/deletion of multi-asset tokens into the internal ledger record. Input Output Global (IOG) engineers, along with SPOs and DApp developers, collectively identified how to reproduce the issue as a unit test that could be included in the standard Cardano node test suite. Following successful testing, this led to a bug fix being implemented, tested, benchmarked, and deployed as a hotfix in the node v.1.35.5 release on Friday, January 27, 2023. Care was taken not to highlight the exact cause of the bug during this process so that it could not be exploited prior to SPOs deploying this new node version. With the fix deployed, the Cardano SPO and developer community have not seen any further instances of this issue.

Further Details

You can read more details on the incident and how it was managed from SundaeSwap’s Pi Lanningham here. Thanks again to all the community for its support in identifying and fixing this bug.

· 2 min read
Jared Corduan

High level summary

We are still heavily involved in work related to preparing the next release. The other main thing we have worked on is experimentation about how we will handle the DRep stake distribution for CIP-1694 in the conway ledger era. Lastly, we merged a fix for node-4826 into our main branch (there will be a post-mortem shortly).

Low level summary

Support for the next release

  • pull-3363 - Fix problems relating to Arbitrary instances used by consensus.
  • pull-3361 - Remove the alonze genesis from the conway genesis.
  • pull-3360 - Translate bad pointer addresses to valid ones in conway.
  • pull-3357 - Fix a bug relating to zero valued ADA in the script context.
  • pull-3356 - Added needed instances (Arbitrary and Serialization) for conway integration.
  • pull-3345 - Added helper functions for the CLI.
  • pull-3342 - Fix a bug with a CLI helper function (having to do with deposit tracking).

Experiments for DRep stake distribution

Adding another stake distribution to the ledger state presents some new challenges. We would like to be able to use the current stake distribution at the epoch boundary for DRep voting so that people can always vote themselves in time for any proposal. To this end, we have a prototype of an incremental computation based on the incremental lambda calculus, together with tests and benchmarks (which are very promising). See pull-3344.

Additionally, more of the ledger state is going to need to be rearranged to accomodate the new incremental computations. We have two draft PRs up for possibles solution. See pull-3353 and pull-3364.

Technical debt and bug fixes

Documentation changes

  • pull-3354 - Rename "optional datums" with "supplemental datums" in the alonzo spec.
  • pull-3352 - Add a section to the Shelly errata about the individual deposit tracking.
  • pull-3351 - Further clarify the details regarding the script integrity hash.
  • pull-3350 - Some cleanup of the Babbage spec.