Skip to content

Support proper encoding/decoding of TX metadata #1136

@agaffney

Description

@agaffney

Create a ledger/common.Metadatum type that can encode/decode TX metadata as specified in the CDDL:

https://github.com/IntersectMBO/cardano-ledger/blob/693218df6cd90263da24e6c2118bac420ceea3a1/eras/conway/impl/cddl-files/conway.cddl#L712-L717

This should be a single type that supports recursive encoding/decoding of the supported data structure, similar to cbor.Value. Replace the use of cbor.LazyValue for decoding metadata in the various per-era Transaction types with this new type. Create some decoding tests using metadata from a few on-chain TXs.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions