diff --git a/src/lib/shared_utils/src/constant.rs b/src/lib/shared_utils/src/constant.rs index b886fd1b..29ca5294 100644 --- a/src/lib/shared_utils/src/constant.rs +++ b/src/lib/shared_utils/src/constant.rs @@ -39,7 +39,7 @@ pub const COST_PER_BILLION_INSTRUCTION_EXECUTED: u128 = 1_000_000_000; //1B cycl pub const ASSUMED_NUMBER_OF_INGRESS_CALL_PER_DAY: u128 = 10; pub const ASSUMED_BYTES_PER_INGRESS_CALL: u128 = 100; // 100 bytes pub const ASSUMED_NUMBER_OF_INSTRUCTIONS_PER_INGRESS_CALL: u128 = 5_000_000_000; //5B instructions (no matter the number of instructions executed 5B is reserved) -pub const RESERVED_NUMBER_OF_INSTRUCTIONS_FOR_INSTALL_CODE: u128 = 200_000_000_000; //200B instructions +pub const RESERVED_NUMBER_OF_INSTRUCTIONS_FOR_INSTALL_CODE: u128 = 300_000_000_000; //200B instructions pub const THRESHOLD_NUMBER_OF_DAYS_TO_KEEP_CANISTER_RUNNING: u128 = 1; pub const MAX_NUMBER_OF_DAYS_TO_KEEP_CANISTER_RUNNING: u128 = 7; diff --git a/src/lib/shared_utils/src/cycles.rs b/src/lib/shared_utils/src/cycles.rs index 895dccb3..489229a9 100644 --- a/src/lib/shared_utils/src/cycles.rs +++ b/src/lib/shared_utils/src/cycles.rs @@ -122,8 +122,7 @@ pub fn calculate_required_cycles_for_upgrading( * COST_PER_BILLION_INSTRUCTION_EXECUTED) / 1_000_000_000); - //100B cycles to safeguard the upgrade process - freezing_threshold_cycles + cycles_required_for_upgrade_execution + 100_000_000_000 + freezing_threshold_cycles + cycles_required_for_upgrade_execution } #[cfg(test)]