second of the upstream TODOs. addresses the `// pub certificates: TODO` comment in transaction/model.rs and the `certificates: None, // TODO` in conway.rs:243. implementation: - new field: pub certificates: Option<Vec<Vec<u8>>> on StagingTransaction. cbor bytes per cert (each entry is conway::Certificate) — same opaque- bytes pattern as auxiliary_data, for the same reason (Certificate doesn't impl Eq). - builder: .add_certificate(cbor_bytes) and .clear_certificates(). - conway::build_conway_raw decodes each entry via Certificate::decode_fragment + plumbs into TransactionBody.certificates via NonEmptySet::from_vec. fragment-decode failures map to TxBuilderError::CorruptedTxBytes (same as aux_data path). tests: - certificates_plumb_through_to_tx_body: encodes a StakeRegistration(AddrKeyhash([7;28])), attaches, builds, decodes resulting tx, asserts the cert round-trips byte-for-byte. - no_certificates_means_none: confirms unset path keeps body.certificates None (no spurious empty Set). unblocks aldabra phase 4.6 stake delegation. PR upstream still pending; this is part of the same vendored fork as the auxiliary_data work. |
||
|---|---|---|
| .. | ||
| src | ||
| Cargo.toml | ||
| README.md | ||