mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
chore: bump c-kzg and add serde feature (#4499)
This commit is contained in:
@ -32,7 +32,7 @@ secp256k1 = { workspace = true, default-features = false, features = [
|
||||
] }
|
||||
|
||||
# for eip-4844
|
||||
c-kzg = { workspace = true }
|
||||
c-kzg = { workspace = true, features = ["serde"] }
|
||||
|
||||
# used for forkid
|
||||
crc = "3"
|
||||
|
||||
@ -51,7 +51,7 @@ pub static MAINNET_KZG_TRUSTED_SETUP: Lazy<Arc<KzgSettings>> = Lazy::new(|| {
|
||||
pub fn load_trusted_setup_from_bytes(bytes: &[u8]) -> Result<KzgSettings, LoadKzgSettingsError> {
|
||||
let mut file = tempfile::NamedTempFile::new().map_err(LoadKzgSettingsError::TempFileErr)?;
|
||||
file.write_all(bytes).map_err(LoadKzgSettingsError::TempFileErr)?;
|
||||
KzgSettings::load_trusted_setup_file(file.path().into()).map_err(LoadKzgSettingsError::KzgError)
|
||||
KzgSettings::load_trusted_setup_file(file.path()).map_err(LoadKzgSettingsError::KzgError)
|
||||
}
|
||||
|
||||
/// Error type for loading the trusted setup.
|
||||
|
||||
Reference in New Issue
Block a user