Skip to content

Commit

Permalink
chore!: reinstate 2 min blocks for dibbler (#3720)
Browse files Browse the repository at this point in the history
Description
---

- Updates dibble consensus to 2-minute blocks
- Updates dibbler genesis timestamp

Motivation and Context
---
Dibbler block times are too fast

How Has This Been Tested?
---
  • Loading branch information
sdbondi committed Jan 20, 2022
1 parent e850cf0 commit 3c5890d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion base_layer/core/src/blocks/genesis_block.rs
Expand Up @@ -245,7 +245,7 @@ fn get_dibbler_genesis_block_raw() -> Block {
);
body.sort();
// set genesis timestamp
let genesis = DateTime::parse_from_rfc2822("07 Jan 2022 00:00:00 +0200").unwrap();
let genesis = DateTime::parse_from_rfc2822("20 Jan 2022 00:00:00 +0200").unwrap();
let timestamp = genesis.timestamp() as u64;
Block {
header: BlockHeader {
Expand Down
14 changes: 7 additions & 7 deletions base_layer/core/src/consensus/consensus_constants.rs
Expand Up @@ -248,10 +248,10 @@ impl ConsensusConstants {
let mut algos = HashMap::new();
// setting sha3/monero to 40/60 split
algos.insert(PowAlgorithm::Sha3, PowAlgorithmConstants {
max_target_time: 180,
min_difficulty: 60_00.into(),
max_target_time: 1800,
min_difficulty: 60_000_000.into(),
max_difficulty: u64::MAX.into(),
target_time: 30,
target_time: 300,
});
algos.insert(PowAlgorithm::Monero, PowAlgorithmConstants {
max_target_time: 1200,
Expand Down Expand Up @@ -320,15 +320,15 @@ impl ConsensusConstants {
// sha3/monero to 40/60 split
algos.insert(PowAlgorithm::Sha3, PowAlgorithmConstants {
max_target_time: 1800,
min_difficulty: 60_000.into(),
min_difficulty: 60_000_000.into(),
max_difficulty: u64::MAX.into(),
target_time: 30,
target_time: 300,
});
algos.insert(PowAlgorithm::Monero, PowAlgorithmConstants {
max_target_time: 1200,
min_difficulty: 60.into(),
min_difficulty: 60_000.into(),
max_difficulty: u64::MAX.into(),
target_time: 20,
target_time: 200,
});
vec![ConsensusConstants {
effective_from_height: 0,
Expand Down

0 comments on commit 3c5890d

Please sign in to comment.