alloy-rs / core

High-performance, well-tested & documented core libraries for Ethereum, in Rust
https://alloy.rs
Apache License 2.0
792 stars 155 forks source link

feat: expand Seal api #773

Closed prestwich closed 1 month ago

prestwich commented 1 month ago

Motivation

Was working on https://github.com/alloy-rs/alloy/pull/1485 and it seemed like there were a few holes in the API

this is a breaking change as it flattens the serde object

Solution

PR Checklist

prestwich commented 1 month ago

makes sense, this type should flatten and renaming seal -> hash is more useful

we can rename to hash if you'd prefer. right now it only allows that as a deser alias, while still producing seal during serialization

This PR includes a serde helper mod for renaming to hash https://github.com/alloy-rs/alloy/pull/1485