Skip to content

Commit

Permalink
cargo troubles
Browse files Browse the repository at this point in the history
  • Loading branch information
debjit-bw committed Jan 17, 2025
1 parent 12819f5 commit 023b1b9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
5 changes: 3 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ revm-primitives = { version = "14.0.0", features = [
"std",
], default-features = false }

serde = { version = "1.0", default-features = false }
serde = { version = "1.0", features = ["derive"], default-features = false}
serde_json = "1.0.94"
serde_with = "3.3.0"
hex = "0.4.3"
Expand Down Expand Up @@ -91,4 +91,5 @@ libc = "0.2"
default = ["jemalloc"]
jemalloc = ["dep:tikv-jemallocator"]
testing = []
failing-tests = []
failing-tests = []
serde = []
10 changes: 6 additions & 4 deletions src/spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ use reth_cli::chainspec::{parse_genesis, ChainSpecParser};
use reth_ethereum_forks::hardfork;
use reth_network_peers::{parse_nodes, NodeRecord};
use revm_primitives::{b256, B256, U256};
#[cfg(feature = "serde")]
use serde::{Deserialize, Serialize};

const GNOSIS_NODES: &[&str] = &[
"enode://fb14d72321ee823fcf21e163091849ee42e0f6ac0cddc737d79e324b0a734c4fc51823ef0a96b749c954483c25e8d2e534d1d5fc2619ea22d58671aff96f5188@65.109.103.148:30303",
Expand Down Expand Up @@ -355,7 +357,7 @@ pub struct GnosisChainSpecParser;
impl ChainSpecParser for GnosisChainSpecParser {
type ChainSpec = GnosisChainSpec;

const SUPPORTED_CHAINS: &'static [&'static str] = &["gnosis", "chiado"];
const SUPPORTED_CHAINS: &'static [&'static str] = &["chiado", "gnosis"];

fn parse(s: &str) -> eyre::Result<Arc<Self::ChainSpec>> {
chain_value_parser(s)
Expand All @@ -368,12 +370,12 @@ impl ChainSpecParser for GnosisChainSpecParser {
/// to a json file, or a json formatted string in-memory. The json needs to be a Genesis struct.
pub fn chain_value_parser(s: &str) -> eyre::Result<Arc<GnosisChainSpec>, eyre::Error> {
Ok(match s {
"gnosis" => Arc::new(GnosisChainSpec::from(parse_genesis(
"./scripts/mainnet_post_merge.json",
)?)),
"chiado" => Arc::new(GnosisChainSpec::from(parse_genesis(
"./scripts/chiado_genesis_alloc.json",
)?)),
"gnosis" => Arc::new(GnosisChainSpec::from(parse_genesis(
"./scripts/mainnet_post_merge.json",
)?)),
_ => Arc::new(parse_genesis(s)?.into()),
})
}

0 comments on commit 023b1b9

Please sign in to comment.