Skip to content

Commit

Permalink
Problem: london hardfork number failed validation (#771)
Browse files Browse the repository at this point in the history
* fix upgrade set parameters

* changelog
  • Loading branch information
yihuang authored Nov 17, 2022
1 parent a6f5bbc commit 4d14c8f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Changelog

*Nov 17, 2022*

## v1.0.0-rc4

### Bug Fixes

- [#771](https://github.com/crypto-org-chain/cronos/pull/771) Fix london hardfork number in testnet3 parameters.

*Nov 13, 2022*

## v1.0.0-rc3

### State Machine Breaking
Expand Down
6 changes: 6 additions & 0 deletions app/upgrades.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package app
import (
"fmt"

sdkmath "cosmossdk.io/math"
storetypes "github.com/cosmos/cosmos-sdk/store/types"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"
Expand All @@ -21,6 +22,11 @@ func (app *App) RegisterUpgradeHandlers(experimental bool) {
// Ref: https://github.com/crypto-org-chain/cronos/issues/755
params := app.EvmKeeper.GetParams(ctx)
params.ExtraEIPs = []int64{}

// fix the incorrect value on testnet parameters
zero := sdkmath.ZeroInt()
params.ChainConfig.LondonBlock = &zero

app.EvmKeeper.SetParams(ctx, params)
return m, nil
}
Expand Down

0 comments on commit 4d14c8f

Please sign in to comment.