From 5a2977a8085cbeba4b7d52f6045b9e85ece48261 Mon Sep 17 00:00:00 2001 From: claravanstaden Date: Tue, 7 Nov 2023 14:07:39 +0200 Subject: [PATCH 1/4] updates fee after fixing decimals --- cumulus/parachains/common/src/snowbridge_config.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cumulus/parachains/common/src/snowbridge_config.rs b/cumulus/parachains/common/src/snowbridge_config.rs index 3cc896d95d6f..87073b6aa501 100644 --- a/cumulus/parachains/common/src/snowbridge_config.rs +++ b/cumulus/parachains/common/src/snowbridge_config.rs @@ -2,5 +2,5 @@ frame_support::parameter_types! { /// User fee for ERC20 token transfer back to Ethereum. /// (initially was calculated by test `OutboundQueue::calculate_fees` - ETH/ROC 1/400 and fee_per_gas 15 GWEI = 22698000000 + *25%) /// Needs to be more than fee calculated from DefaultFeeConfig FeeConfigRecord in snowbridge:parachain/pallets/outbound-queue/src/lib.rs - pub const BridgeHubEthereumBaseFeeInRocs: u128 = 3_028_372_500_000; + pub const BridgeHubEthereumBaseFeeInRocs: u128 = 2_750_872_500_000; } From 08fe447390994a5c639587628d5502420c07e6d0 Mon Sep 17 00:00:00 2001 From: claravanstaden Date: Tue, 7 Nov 2023 14:38:55 +0200 Subject: [PATCH 2/4] adds fee in dot --- cumulus/parachains/common/src/snowbridge_config.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/cumulus/parachains/common/src/snowbridge_config.rs b/cumulus/parachains/common/src/snowbridge_config.rs index 87073b6aa501..ce812846bc19 100644 --- a/cumulus/parachains/common/src/snowbridge_config.rs +++ b/cumulus/parachains/common/src/snowbridge_config.rs @@ -2,5 +2,6 @@ frame_support::parameter_types! { /// User fee for ERC20 token transfer back to Ethereum. /// (initially was calculated by test `OutboundQueue::calculate_fees` - ETH/ROC 1/400 and fee_per_gas 15 GWEI = 22698000000 + *25%) /// Needs to be more than fee calculated from DefaultFeeConfig FeeConfigRecord in snowbridge:parachain/pallets/outbound-queue/src/lib.rs + pub const BridgeHubEthereumBaseFeeInDot: u128 = 27_508_725_000; pub const BridgeHubEthereumBaseFeeInRocs: u128 = 2_750_872_500_000; } From 5d3aadf225aed81ec1e5fcee1d16e07820b0e855 Mon Sep 17 00:00:00 2001 From: claravanstaden Date: Tue, 7 Nov 2023 14:43:24 +0200 Subject: [PATCH 3/4] adds fee in ksm --- cumulus/parachains/common/src/snowbridge_config.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cumulus/parachains/common/src/snowbridge_config.rs b/cumulus/parachains/common/src/snowbridge_config.rs index ce812846bc19..b04f9869e239 100644 --- a/cumulus/parachains/common/src/snowbridge_config.rs +++ b/cumulus/parachains/common/src/snowbridge_config.rs @@ -2,6 +2,7 @@ frame_support::parameter_types! { /// User fee for ERC20 token transfer back to Ethereum. /// (initially was calculated by test `OutboundQueue::calculate_fees` - ETH/ROC 1/400 and fee_per_gas 15 GWEI = 22698000000 + *25%) /// Needs to be more than fee calculated from DefaultFeeConfig FeeConfigRecord in snowbridge:parachain/pallets/outbound-queue/src/lib.rs - pub const BridgeHubEthereumBaseFeeInDot: u128 = 27_508_725_000; + pub const BridgeHubEthereumBaseFeeInDOT: u128 = 27_508_725_000; + pub const BridgeHubEthereumBaseFeeInKSM: u128 = 2_750_872_500_000; pub const BridgeHubEthereumBaseFeeInRocs: u128 = 2_750_872_500_000; } From 1c9e13bce4ff217ff2e0c1134e82031cacfe5b8b Mon Sep 17 00:00:00 2001 From: claravanstaden Date: Tue, 7 Nov 2023 16:54:42 +0200 Subject: [PATCH 4/4] updates comment --- cumulus/parachains/common/src/snowbridge_config.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cumulus/parachains/common/src/snowbridge_config.rs b/cumulus/parachains/common/src/snowbridge_config.rs index b04f9869e239..1e957d4cd291 100644 --- a/cumulus/parachains/common/src/snowbridge_config.rs +++ b/cumulus/parachains/common/src/snowbridge_config.rs @@ -1,7 +1,8 @@ frame_support::parameter_types! { /// User fee for ERC20 token transfer back to Ethereum. - /// (initially was calculated by test `OutboundQueue::calculate_fees` - ETH/ROC 1/400 and fee_per_gas 15 GWEI = 22698000000 + *25%) + /// (initially was calculated by test `OutboundQueue::calculate_fees` - ETH/ROC 1/400 and fee_per_gas 20 GWEI = 2200698000000 + *25%) /// Needs to be more than fee calculated from DefaultFeeConfig FeeConfigRecord in snowbridge:parachain/pallets/outbound-queue/src/lib.rs + /// Polkadot uses 12 decimals, Kusama and Rococo 10 decimals. pub const BridgeHubEthereumBaseFeeInDOT: u128 = 27_508_725_000; pub const BridgeHubEthereumBaseFeeInKSM: u128 = 2_750_872_500_000; pub const BridgeHubEthereumBaseFeeInRocs: u128 = 2_750_872_500_000;