diff --git a/CHANGELOG.md b/CHANGELOG.md index a1997238..50ab94ce 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,6 +45,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +[#367] Set ETH block delay to 96 blocks [#362](https://github.com/umee-network/peggo/pull/362) Update umeed to v3. [#343](https://github.com/umee-network/peggo/pull/343) Upgrade to cosmos-sdk v0.46.1. [#341](https://github.com/umee-network/peggo/pull/341) Fix linter. diff --git a/orchestrator/main_loops.go b/orchestrator/main_loops.go index e24fe87c..8c24e2a6 100644 --- a/orchestrator/main_loops.go +++ b/orchestrator/main_loops.go @@ -501,9 +501,12 @@ func (p *gravityOrchestrator) ERC20ToDenom(ctx context.Context, tokenAddr ethcmn // mechanism to prevent relaying an event that is not yet considered final. func getEthBlockDelay(chainID uint64) uint64 { switch chainID { - // Mainline Ethereum, Ethereum classic, or the Ropsten, Kotti, Mordor testnets - // all POW Chains - case 1, 3, 6, 7: + // Mainline Ethereum + case 1: + return 96 + + // Ethereum classic, or the Ropsten, Kotti, Mordor testnets all POW Chains + case 3, 6, 7: return 13 // Dev, our own Gravity Ethereum testnet, and Hardhat respectively @@ -519,6 +522,6 @@ func getEthBlockDelay(chainID uint64) uint64 { // assume the safe option (POW) where we don't know default: - return 13 + return 96 } } diff --git a/orchestrator/main_loops_test.go b/orchestrator/main_loops_test.go index 0d6e2353..754d973d 100644 --- a/orchestrator/main_loops_test.go +++ b/orchestrator/main_loops_test.go @@ -55,8 +55,8 @@ func TestERC20ToDenom(t *testing.T) { } func TestGetEthBlockDelay(t *testing.T) { - assert.Equal(t, uint64(13), getEthBlockDelay(1)) + assert.Equal(t, uint64(96), getEthBlockDelay(1)) assert.Equal(t, uint64(0), getEthBlockDelay(2018)) assert.Equal(t, uint64(10), getEthBlockDelay(5)) - assert.Equal(t, uint64(13), getEthBlockDelay(1235)) + assert.Equal(t, uint64(96), getEthBlockDelay(1235)) }