reuse Morden for Classic Testnet

This commit is contained in:
Igor Artamonov 2016-12-12 19:50:32 +00:00
parent 6742b080f5
commit e61d14d7f7
6 changed files with 13 additions and 75 deletions

View File

@ -1,58 +0,0 @@
{
"name": "Ethereum Classic Morden Testnet",
"forkName": "classic",
"engine": {
"Ethash": {
"params": {
"gasLimitBoundDivisor": "0x0400",
"minimumDifficulty": "0x020000",
"difficultyBoundDivisor": "0x0800",
"durationLimit": "0x0d",
"blockReward": "0x4563918244F40000",
"registrar": "0x52dff57a8a1532e6afb3dc07e2af58bb9eb05b3d",
"homesteadTransition": 494000,
"eip150Transition": 1783000,
"eip155Transition": 1915000,
"eip160Transition": 1915000,
"ecip1010PauseTransition": 1915000,
"ecip1010ContinueTransition": 3415000,
"eip161abcTransition": "0x7fffffffffffffff",
"eip161dTransition": "0x7fffffffffffffff"
}
}
},
"params": {
"accountStartNonce": "0x0100000",
"maximumExtraDataSize": "0x20",
"minGasLimit": "0x1388",
"networkID" : "0x2",
"forkBlock": "0x1b34d8",
"forkCanonHash": "0xf376243aeff1f256d970714c3de9fd78fa4e63cf63e32a51fe1169e375d98145"
},
"genesis": {
"seal": {
"ethereum": {
"nonce": "0x00006d6f7264656e",
"mixHash": "0x00000000000000000000000000000000000000647572616c65787365646c6578"
}
},
"difficulty": "0x20000",
"author": "0x0000000000000000000000000000000000000000",
"timestamp": "0x00",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"extraData": "0x",
"gasLimit": "0x2fefd8"
},
"nodes": [
"enode://e731347db0521f3476e6bbbb83375dcd7133a1601425ebd15fd10f3835fd4c304fba6282087ca5a0deeafadf0aa0d4fd56c3323331901c1f38bd181c283e3e35@128.199.55.137:30303",
"enode://ceb5c0f85eb994dbe9693bf46d99b03f6b838d17cc74e68d5eb003171ff39e5f120b17f965b267c319303f94d80b9d994b77062fb1486d76ce95d9f3d8fe1cb4@46.101.122.141:30303"
],
"accounts": {
"0000000000000000000000000000000000000001": { "balance": "1", "nonce": "1048576", "builtin": { "name": "ecrecover", "pricing": { "linear": { "base": 3000, "word": 0 } } } },
"0000000000000000000000000000000000000002": { "balance": "1", "nonce": "1048576", "builtin": { "name": "sha256", "pricing": { "linear": { "base": 60, "word": 12 } } } },
"0000000000000000000000000000000000000003": { "balance": "1", "nonce": "1048576", "builtin": { "name": "ripemd160", "pricing": { "linear": { "base": 600, "word": 120 } } } },
"0000000000000000000000000000000000000004": { "balance": "1", "nonce": "1048576", "builtin": { "name": "identity", "pricing": { "linear": { "base": 15, "word": 3 } } } },
"102e61f5d8f9bc71d0ad4a084df4e65e05ce0e1c": { "balance": "1606938044258990275541962092341162602522202993782792835301376", "nonce": "1048576" }
}
}

View File

@ -9,12 +9,15 @@
"durationLimit": "0x0d", "durationLimit": "0x0d",
"blockReward": "0x4563918244F40000", "blockReward": "0x4563918244F40000",
"registrar": "0x52dff57a8a1532e6afb3dc07e2af58bb9eb05b3d", "registrar": "0x52dff57a8a1532e6afb3dc07e2af58bb9eb05b3d",
"homesteadTransition": "0x789b0", "homesteadTransition": 494000,
"eip150Transition": "0x1b34d8", "eip150Transition": 1783000,
"eip155Transition": 1885000, "eip155Transition": 1915000,
"eip160Transition": 1885000, "eip160Transition": 1915000,
"eip161abcTransition": 1885000, "ecip1010PauseTransition": 1915000,
"eip161dTransition": 1885000 "ecip1010ContinueTransition": 3415000,
"eip161abcTransition": "0x7fffffffffffffff",
"eip161dTransition": "0x7fffffffffffffff"
} }
} }
}, },

@ -1 +1 @@
Subproject commit e8f4624b7f1a15c63674eecf577c7ab76c3b16be Subproject commit 9028c4801fd39fbb71a9796979182549a24e81c8

View File

@ -42,9 +42,6 @@ pub fn new_frontier() -> Spec { load(include_bytes!("../../res/ethereum/frontier
/// Create a new Frontier mainnet chain spec without the DAO hardfork. /// Create a new Frontier mainnet chain spec without the DAO hardfork.
pub fn new_classic() -> Spec { load(include_bytes!("../../res/ethereum/classic.json")) } pub fn new_classic() -> Spec { load(include_bytes!("../../res/ethereum/classic.json")) }
/// Create a new Morden chain spec configured for Thereum Classic
pub fn new_classic_morden() -> Spec { load(include_bytes!("../../res/ethereum/classic-morden.json")) }
/// Create a new Frontier mainnet chain spec without the DAO hardfork. /// Create a new Frontier mainnet chain spec without the DAO hardfork.
pub fn new_expanse() -> Spec { load(include_bytes!("../../res/ethereum/expanse.json")) } pub fn new_expanse() -> Spec { load(include_bytes!("../../res/ethereum/expanse.json")) }

View File

@ -33,7 +33,7 @@ Operating Options:
--chain CHAIN Specify the blockchain type. CHAIN may be either a --chain CHAIN Specify the blockchain type. CHAIN may be either a
JSON chain specification file or olympic, frontier, JSON chain specification file or olympic, frontier,
homestead, mainnet, morden, ropsten, classic, expanse, homestead, mainnet, morden, ropsten, classic, expanse,
testnet, classic-morden or dev (default: {flag_chain}). testnet or dev (default: {flag_chain}).
-d --db-path PATH Specify the database & configuration directory path -d --db-path PATH Specify the database & configuration directory path
(default: {flag_db_path}). (default: {flag_db_path}).
--keys-path PATH Specify the path for JSON key files to be found --keys-path PATH Specify the path for JSON key files to be found

View File

@ -31,7 +31,6 @@ pub enum SpecType {
Ropsten, Ropsten,
Olympic, Olympic,
Classic, Classic,
ClassicTestnet,
Expanse, Expanse,
Dev, Dev,
Custom(String), Custom(String),
@ -50,8 +49,7 @@ impl str::FromStr for SpecType {
let spec = match s { let spec = match s {
"frontier" | "homestead" | "mainnet" => SpecType::Mainnet, "frontier" | "homestead" | "mainnet" => SpecType::Mainnet,
"frontier-dogmatic" | "homestead-dogmatic" | "classic" => SpecType::Classic, "frontier-dogmatic" | "homestead-dogmatic" | "classic" => SpecType::Classic,
"classic-testnet" | "classic-morden" => SpecType::ClassicTestnet, "morden" | "testnet" | "classic-testnet" => SpecType::Testnet,
"morden" | "testnet" => SpecType::Testnet,
"ropsten" => SpecType::Ropsten, "ropsten" => SpecType::Ropsten,
"olympic" => SpecType::Olympic, "olympic" => SpecType::Olympic,
"expanse" => SpecType::Expanse, "expanse" => SpecType::Expanse,
@ -70,7 +68,6 @@ impl SpecType {
SpecType::Ropsten => Ok(ethereum::new_ropsten()), SpecType::Ropsten => Ok(ethereum::new_ropsten()),
SpecType::Olympic => Ok(ethereum::new_olympic()), SpecType::Olympic => Ok(ethereum::new_olympic()),
SpecType::Classic => Ok(ethereum::new_classic()), SpecType::Classic => Ok(ethereum::new_classic()),
SpecType::ClassicTestnet => Ok(ethereum::new_classic_morden()),
SpecType::Expanse => Ok(ethereum::new_expanse()), SpecType::Expanse => Ok(ethereum::new_expanse()),
SpecType::Dev => Ok(Spec::new_instant()), SpecType::Dev => Ok(Spec::new_instant()),
SpecType::Custom(ref filename) => { SpecType::Custom(ref filename) => {
@ -292,8 +289,7 @@ mod tests {
assert_eq!(SpecType::Ropsten, "ropsten".parse().unwrap()); assert_eq!(SpecType::Ropsten, "ropsten".parse().unwrap());
assert_eq!(SpecType::Olympic, "olympic".parse().unwrap()); assert_eq!(SpecType::Olympic, "olympic".parse().unwrap());
assert_eq!(SpecType::Classic, "classic".parse().unwrap()); assert_eq!(SpecType::Classic, "classic".parse().unwrap());
assert_eq!(SpecType::ClassicTestnet, "classic-testnet".parse().unwrap()); assert_eq!(SpecType::Testnet, "classic-testnet".parse().unwrap());
assert_eq!(SpecType::ClassicTestnet, "classic-morden".parse().unwrap());
} }
#[test] #[test]