Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Add missing forks to fork ID #11747

Merged
merged 1 commit into from
Jun 1, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion ethcore/spec/src/spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -406,6 +406,7 @@ impl Spec {
params.eip1344_transition,
params.eip1884_transition,
params.eip2028_transition,
params.eip2046_transition,
params.eip2200_advance_transition,
params.eip2315_transition,
params.dust_protection_transition,
Expand All @@ -426,7 +427,17 @@ impl Spec {
ethjson::spec::Engine::Null(null) => Arc::new(NullEngine::new(null.params.into(), machine)),
ethjson::spec::Engine::Ethash(ethash) => {
// Specific transitions for Ethash-based networks
for block in &[ethash.params.homestead_transition, ethash.params.dao_hardfork_transition] {
for block in &[
ethash.params.homestead_transition,
ethash.params.dao_hardfork_transition,
ethash.params.difficulty_hardfork_transition,
ethash.params.bomb_defuse_transition,
ethash.params.eip100b_transition,
ethash.params.ecip1010_pause_transition,
ethash.params.ecip1010_continue_transition,
ethash.params.ecip1017_era_rounds,
ethash.params.expip2_transition,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a typo there?

exip instead of ecip

Copy link
Contributor

@YazzyYaz YazzyYaz Jun 1, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whelps, looks like I misread it as exip instead of expip. explains why I couldn't grep it. Ignore my message, sorry!

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No typo here. It's EXPIP-2 related to Expanse chain, not Classic.

] {
if let Some(block) = *block {
hard_forks.insert(block.into());
}
Expand Down
17 changes: 17 additions & 0 deletions ethcore/sync/src/chain/fork_filter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -140,4 +140,21 @@ mod tests {
],
)
}

#[test]
fn classic_spec() {
test_spec(
|| spec::new_classic(&String::new()),
vec![
1150000,
2500000,
3000000,
5000000,
5900000,
8772000,
9573000,
10500839,
],
)
}
}