Last genesis for T4, unless I messed up something

This commit is contained in:
Ignotus Peverell 2018-10-17 19:36:12 +00:00
parent 6db0bcefa5
commit b5cb227322
No known key found for this signature in database
GPG key ID: 99CD25F39F8F8211
3 changed files with 11 additions and 12 deletions

View file

@ -111,18 +111,19 @@ pub fn genesis_testnet4() -> core::Block {
core::Block::with_header(core::BlockHeader { core::Block::with_header(core::BlockHeader {
height: 0, height: 0,
previous: core::hash::Hash([0xff; 32]), previous: core::hash::Hash([0xff; 32]),
timestamp: Utc.ymd(2018, 10, 17).and_hms(16, 0, 0), timestamp: Utc.ymd(2018, 10, 17).and_hms(20, 0, 0),
pow: ProofOfWork { pow: ProofOfWork {
total_difficulty: Difficulty::from_num(global::initial_block_difficulty()), total_difficulty: Difficulty::from_num(global::initial_block_difficulty()),
scaling_difficulty: global::initial_graph_weight(), scaling_difficulty: global::initial_graph_weight(),
nonce: 4956988373127692, nonce: 8612241555342799290,
proof: Proof::new(vec![ proof: Proof::new(vec![
0xa420dc, 0xc8ffee, 0x10e433e, 0x1de9428, 0x2ed4cea, 0x52d907b, 0x5af0e3f, 0x46f3b4, 0x1135f8c, 0x1a1596f, 0x1e10f71, 0x41c03ea, 0x63fe8e7, 0x65af34f,
0x6b8fcae, 0x8319b53, 0x845ca8c, 0x8d2a13e, 0x8d6e4cc, 0x9349e8d, 0xa7a33c5, 0x73c16d3, 0x8216dc3, 0x9bc75d0, 0xae7d9ad, 0xc1cb12b, 0xc65e957, 0xf67a152,
0xaeac3cb, 0xb193e23, 0xb502e19, 0xb5d9804, 0xc9ac184, 0xd4f4de3, 0xd7a23b8, 0xfac6559, 0x100c3d71, 0x11eea08b, 0x1225dfbb, 0x124d61a1, 0x132a14b4,
0xf1d8660, 0xf443756, 0x10b833d2, 0x11418fc5, 0x11b8aeaf, 0x131836ec, 0x132ab818, 0x13f4ec38, 0x1542d236, 0x155f2df0, 0x1577394e, 0x163c3513, 0x19349845,
0x13a46a55, 0x13df89fe, 0x145d65b5, 0x166f9c3a, 0x166fe0ef, 0x178cb36f, 0x185baf68, 0x19d46953, 0x19f65ed4, 0x1a0411b9, 0x1a2fa039, 0x1a72a06c, 0x1b02ddd2,
0x1bbfe563, 0x1bd637b4, 0x1cfc8382, 0x1d1ed012, 0x1e391ca5, 0x1e999b4c, 0x1f7c6d21, 0x1b594d59, 0x1b7bffd3, 0x1befe12e, 0x1c82e4cd, 0x1d492478, 0x1de132a5,
0x1e578b3c, 0x1ed96855, 0x1f222896, 0x1fea0da6,
]), ]),
}, },
..Default::default() ..Default::default()

View file

@ -68,9 +68,7 @@ pub const TESTNET3_INITIAL_DIFFICULTY: u64 = 30000;
/// Testnet 4 initial block difficulty /// Testnet 4 initial block difficulty
/// 1_000 times natural scale factor for cuckatoo29 /// 1_000 times natural scale factor for cuckatoo29
// TODO: Enable this on real testnet pub const TESTNET4_INITIAL_DIFFICULTY: u64 = 1_000 * (2<<(29-24)) * 29;
// pub const TESTNET4_INITIAL_DIFFICULTY: u64 = 1_000 * (2<<(29-24)) * 29;
pub const TESTNET4_INITIAL_DIFFICULTY: u64 = 1 * (2 << (29 - 24)) * 29;
/// Trigger compaction check on average every day for FAST_SYNC_NODE, /// Trigger compaction check on average every day for FAST_SYNC_NODE,
/// roll the dice on every block to decide, /// roll the dice on every block to decide,

View file

@ -35,7 +35,7 @@ pub const PROTOCOL_VERSION: u32 = 1;
pub const USER_AGENT: &'static str = concat!("MW/Grin ", env!("CARGO_PKG_VERSION")); pub const USER_AGENT: &'static str = concat!("MW/Grin ", env!("CARGO_PKG_VERSION"));
/// Magic number expected in the header of every message /// Magic number expected in the header of every message
const MAGIC: [u8; 2] = [0x47, 0x34]; const MAGIC: [u8; 2] = [0x54, 0x34];
/// Size in bytes of a message header /// Size in bytes of a message header
pub const HEADER_LEN: u64 = 11; pub const HEADER_LEN: u64 = 11;