From cb84099b2e6d757885afe7fe6b596a3850205f65 Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Fri, 14 Feb 2020 21:15:11 -0800 Subject: [PATCH] Add storage rewards pools in development mode only (#8300) automerge --- genesis/src/main.rs | 5 +++-- sdk/src/genesis_config.rs | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/genesis/src/main.rs b/genesis/src/main.rs index ac2b94854b1201..b9b854c5e2c9c8 100644 --- a/genesis/src/main.rs +++ b/genesis/src/main.rs @@ -503,8 +503,9 @@ fn main() -> Result<(), Box> { ); } - // add genesis stuff from storage and stake - solana_storage_program::rewards_pools::add_genesis_accounts(&mut genesis_config); + if operating_mode == OperatingMode::Development { + solana_storage_program::rewards_pools::add_genesis_accounts(&mut genesis_config); + } solana_stake_program::add_genesis_accounts(&mut genesis_config); if let Some(files) = matches.values_of("primordial_accounts_file") { diff --git a/sdk/src/genesis_config.rs b/sdk/src/genesis_config.rs index 52d6082246c0aa..8510fcc11ccdcb 100644 --- a/sdk/src/genesis_config.rs +++ b/sdk/src/genesis_config.rs @@ -23,7 +23,7 @@ use std::{ time::{SystemTime, UNIX_EPOCH}, }; -#[derive(Serialize, Deserialize, Debug, Clone, Copy)] +#[derive(Serialize, Deserialize, Debug, Clone, Copy, PartialEq)] pub enum OperatingMode { SoftLaunch, // Cluster features incrementally enabled over time Development, // All features (including experimental features) available immediately from genesis