Skip to content

Commit

Permalink
Merge pull request #929 from bnb-chain/develop
Browse files Browse the repository at this point in the history
release: draft the release v0.10.8
  • Loading branch information
unclezoro authored Mar 20, 2023
2 parents 291c077 + d94fa45 commit 94936f2
Show file tree
Hide file tree
Showing 15 changed files with 657 additions and 145 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog

## v0.10.8
FEATURES
* [\#895](https://github.com/bnb-chain/node/pull/895) [BEP] feat: add bep 171 upgrade
* [\#924](https://github.com/bnb-chain/node/pull/924) [cli] feat: add gen-consensus-key command in bnbcli

## v0.10.7
FEATURES
* [\#921](https://github.com/bnb-chain/node/pull/921) [config] add LimitConsAddrUpdateIntervalHeight and BEP159Height in assets
Expand Down
1 change: 1 addition & 0 deletions app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,7 @@ func SetUpgradeConfig(upgradeConfig *config.UpgradeConfig) {
upgrade.Mgr.AddUpgradeHeight(upgrade.BEP159, upgradeConfig.BEP159Height)
upgrade.Mgr.AddUpgradeHeight(upgrade.BEP159Phase2, upgradeConfig.BEP159Phase2Height)
upgrade.Mgr.AddUpgradeHeight(upgrade.LimitConsAddrUpdateInterval, upgradeConfig.LimitConsAddrUpdateIntervalHeight)
upgrade.Mgr.AddUpgradeHeight(upgrade.BEP171, upgradeConfig.BEP171Height)
upgrade.Mgr.AddUpgradeHeight(upgrade.BEP173, upgradeConfig.BEP173Height)
upgrade.Mgr.AddUpgradeHeight(upgrade.FixDoubleSignChainId, upgradeConfig.FixDoubleSignChainIdHeight)

Expand Down
3 changes: 3 additions & 0 deletions app/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -543,6 +543,7 @@ type UpgradeConfig struct {
BEP159Height int64 `mapstructure:"BEP159Height"`
BEP159Phase2Height int64 `mapstructure:"BEP159Phase2Height"`
LimitConsAddrUpdateIntervalHeight int64 `mapstructure:"LimitConsAddrUpdateIntervalHeight"`
BEP171Height int64 `mapstructure:"BEP171Height"`
BEP173Height int64 `mapstructure:"BEP173Height"`
FixDoubleSignChainIdHeight int64 `mapstructure:"FixDoubleSignChainIdHeight"`
}
Expand Down Expand Up @@ -575,7 +576,9 @@ func defaultUpgradeConfig() *UpgradeConfig {
BEP82Height: math.MaxInt64,
BEP84Height: math.MaxInt64,
BEP87Height: math.MaxInt64,
BEP171Height: math.MaxInt64,
FixFailAckPackageHeight: math.MaxInt64,

EnableAccountScriptsForCrossChainTransferHeight: math.MaxInt64,
}
}
Expand Down
4 changes: 4 additions & 0 deletions asset/testnet/app.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ FixDoubleSignChainIdHeight = 34587202
BEP159Height = 34587202
#Block height of BEP159Phase2Height upgrade
BEP159Phase2Height = 34963303
# Block height of LimitConsAddrUpdateInterval upgrade
LimitConsAddrUpdateIntervalHeight = 37691120
# Block height of BEP171 upgrade
BEP171Height = 37691120

[query]
# ABCI query interface black list, suggested value: ["custom/gov/proposals", "custom/timelock/timelocks", "custom/atomicSwap/swapcreator", "custom/atomicSwap/swaprecipient"]
Expand Down
9 changes: 4 additions & 5 deletions cmd/bnbcli/main.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package main

import (
"github.com/spf13/cobra"

"github.com/cosmos/cosmos-sdk/client"
"github.com/cosmos/cosmos-sdk/client/keys"
"github.com/cosmos/cosmos-sdk/client/rpc"
Expand All @@ -11,16 +9,16 @@ import (
authcmd "github.com/cosmos/cosmos-sdk/x/auth/client/cli"
bankcmd "github.com/cosmos/cosmos-sdk/x/bank/client/cli"
govcmd "github.com/cosmos/cosmos-sdk/x/gov/client/cli"
sidecmd "github.com/cosmos/cosmos-sdk/x/sidechain/client/cli"

paramcmd "github.com/cosmos/cosmos-sdk/x/paramHub/client/cli"
sidecmd "github.com/cosmos/cosmos-sdk/x/sidechain/client/cli"
slashingcmd "github.com/cosmos/cosmos-sdk/x/slashing/client/cli"
stakecmd "github.com/cosmos/cosmos-sdk/x/stake/client/cli"

"github.com/spf13/cobra"
"github.com/tendermint/tendermint/libs/cli"

"github.com/bnb-chain/node/admin"
"github.com/bnb-chain/node/app"
"github.com/bnb-chain/node/cmd/bnbcli/utils"
"github.com/bnb-chain/node/common"
"github.com/bnb-chain/node/common/types"
accountcmd "github.com/bnb-chain/node/plugins/account/client/cli"
Expand Down Expand Up @@ -84,6 +82,7 @@ func main() {
client.LineBreak,
apiserv.ServeCommand(cdc),
keys.Commands(),
utils.Commands(),
client.LineBreak,
version.VersionCmd,
)
Expand Down
36 changes: 36 additions & 0 deletions cmd/bnbcli/utils/consensus_key.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
package utils

import (
"fmt"

"github.com/cosmos/cosmos-sdk/types"
"github.com/spf13/cobra"
"github.com/tendermint/tendermint/privval"
)

const (
outputPathFlag = "output-path"
)

func genConsensusKeyCommand() *cobra.Command {
cmd := &cobra.Command{
Use: "gen-consensus-key",
Short: "generate the JSON file containing the private key to use as a validator in the consensus protocol",
RunE: runGenConsensusKeyCmd,
}
cmd.Flags().String(outputPathFlag, "./priv_validator_key.json", "The target path of the output file")
return cmd
}

func runGenConsensusKeyCmd(cmd *cobra.Command, args []string) error {
flags := cmd.Flags()

outputPath, _ := flags.GetString(outputPathFlag)

filePv := privval.GenFilePV(outputPath, "")
filePv.Key.Save()
fmt.Printf("The consensus key has been generated and saved to %s successfully\n", outputPath)
pubkey := types.MustBech32ifyConsPub(filePv.Key.PubKey)
fmt.Printf("The consensus pubkey is %s\n", pubkey)
return nil
}
16 changes: 16 additions & 0 deletions cmd/bnbcli/utils/root.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package utils

import (
"github.com/spf13/cobra"
)

func Commands() *cobra.Command {
cmd := &cobra.Command{
Use: "utils",
Short: "Utilities for interacting with BNB Beacon Chain",
}
cmd.AddCommand(
genConsensusKeyCommand(),
)
return cmd
}
1 change: 1 addition & 0 deletions common/upgrade/upgrade.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ const (
BEP159 = sdk.BEP159 // https://github.com/bnb-chain/BEPs/pull/159 New Staking Mechanism
BEP159Phase2 = sdk.BEP159Phase2
LimitConsAddrUpdateInterval = sdk.LimitConsAddrUpdateInterval
BEP171 = sdk.BEP171 // https://github.com/bnb-chain/BEPs/pull/171 Security Enhancement for Cross-Chain Module
BEP173 = sdk.BEP173 // https://github.com/bnb-chain/BEPs/pull/173 Text Proposal
FixDoubleSignChainId = sdk.FixDoubleSignChainId
)
Expand Down
4 changes: 2 additions & 2 deletions e2e/fee.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"io/ioutil"
"log"

"github.com/binance-chain/go-sdk/client/rpc"
sdkTypes "github.com/binance-chain/go-sdk/common/types"
"github.com/bnb-chain/go-sdk/client/rpc"
sdkTypes "github.com/bnb-chain/go-sdk/common/types"
"golang.org/x/xerrors"
)

Expand Down
79 changes: 48 additions & 31 deletions e2e/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,70 +3,87 @@ module github.com/bnb-chain/node/e2e
go 1.17

require (
github.com/binance-chain/go-sdk v1.2.7
github.com/bnb-chain/go-sdk v1.3.2-0.20230302035805-64e27e7454a2
github.com/cosmos/cosmos-sdk v0.25.0
github.com/tendermint/go-amino v0.15.0
github.com/tendermint/tendermint v0.32.3
github.com/tendermint/tendermint v0.35.9
github.com/tidwall/gjson v1.14.3
golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f
)

require (
github.com/bartekn/go-bip39 v0.0.0-20171116152956-a05967ea095d // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/binance-chain/ledger-cosmos-go v0.9.9-binance.1 // indirect
github.com/btcsuite/btcd v0.20.1-beta // indirect
github.com/btcsuite/btcutil v0.0.0-20190425235716-9e5f4b9a998d // indirect
github.com/bgentry/speakeasy v0.1.0 // indirect
github.com/bnb-chain/ics23 v0.1.0 // indirect
github.com/bnb-chain/node v0.10.7 // indirect
github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect
github.com/btcsuite/btcd/btcutil v1.1.3 // indirect
github.com/cespare/xxhash/v2 v2.1.2 // indirect
github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d // indirect
github.com/cosmos/ledger-go v0.9.2 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect
github.com/etcd-io/bbolt v1.3.3 // indirect
github.com/fsnotify/fsnotify v1.4.7 // indirect
github.com/fsnotify/fsnotify v1.4.9 // indirect
github.com/go-kit/kit v0.9.0 // indirect
github.com/go-logfmt/logfmt v0.4.0 // indirect
github.com/gogo/protobuf v1.3.1 // indirect
github.com/golang/protobuf v1.3.2 // indirect
github.com/golang/snappy v0.0.1 // indirect
github.com/gorilla/websocket v1.4.1-0.20190629185528-ae1634f6a989 // indirect
github.com/go-logfmt/logfmt v0.5.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/golang/snappy v0.0.4 // indirect
github.com/google/btree v1.0.0 // indirect
github.com/gorilla/mux v1.7.3 // indirect
github.com/gorilla/websocket v1.5.0 // indirect
github.com/hashicorp/golang-lru v0.5.3 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/inconshreveable/mousetrap v1.0.0 // indirect
github.com/jmhodges/levigo v1.0.0 // indirect
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515 // indirect
github.com/libp2p/go-buffer-pool v0.0.2 // indirect
github.com/magiconair/properties v1.8.1 // indirect
github.com/mattn/go-isatty v0.0.10 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
github.com/mitchellh/go-homedir v1.1.0 // indirect
github.com/mitchellh/mapstructure v1.1.2 // indirect
github.com/pelletier/go-toml v1.4.0 // indirect
github.com/pkg/errors v0.8.1 // indirect
github.com/prometheus/client_golang v1.1.0 // indirect
github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90 // indirect
github.com/prometheus/common v0.6.0 // indirect
github.com/prometheus/procfs v0.0.3 // indirect
github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/prometheus/client_golang v1.14.0 // indirect
github.com/prometheus/client_model v0.3.0 // indirect
github.com/prometheus/common v0.37.0 // indirect
github.com/prometheus/procfs v0.8.0 // indirect
github.com/rcrowley/go-metrics v0.0.0-20190826022208-cac0b30c2563 // indirect
github.com/rs/cors v1.6.0 // indirect
github.com/spf13/afero v1.2.2 // indirect
github.com/spf13/cast v1.3.0 // indirect
github.com/spf13/cobra v0.0.5 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/spf13/pflag v1.0.3 // indirect
github.com/spf13/viper v1.4.0 // indirect
github.com/syndtr/goleveldb v1.0.1-0.20190923125748-758128399b1d // indirect
github.com/stretchr/testify v1.8.1 // indirect
github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect
github.com/tendermint/btcd v0.1.1 // indirect
github.com/tendermint/iavl v0.12.4 // indirect
github.com/tendermint/tm-db v0.1.1 // indirect
github.com/tidwall/match v1.1.1 // indirect
github.com/tidwall/pretty v1.2.0 // indirect
github.com/zondax/hid v0.9.0 // indirect
github.com/zondax/ledger-go v0.9.0 // indirect
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519 // indirect
golang.org/x/net v0.3.0 // indirect
golang.org/x/sys v0.3.0 // indirect
golang.org/x/text v0.5.0 // indirect
google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb // indirect
google.golang.org/grpc v1.23.0 // indirect
gopkg.in/yaml.v2 v2.2.4 // indirect
github.com/zondax/ledger-cosmos-go v0.9.9 // indirect
golang.org/x/crypto v0.5.0 // indirect
golang.org/x/net v0.5.0 // indirect
golang.org/x/sys v0.4.0 // indirect
golang.org/x/text v0.6.0 // indirect
google.golang.org/genproto v0.0.0-20200825200019-8632dd797987 // indirect
google.golang.org/grpc v1.31.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

replace (
github.com/binance-chain/go-sdk => github.com/bnb-chain/go-sdk v1.2.8
github.com/cosmos/cosmos-sdk => github.com/bnb-chain/bnc-cosmos-sdk v0.25.4-0.20221221115251-f9e69ff1b273
github.com/tendermint/tendermint => github.com/bnb-chain/bnc-tendermint v0.32.3-binance.3.0.20221109023026-379ddbab19d1
github.com/cosmos/cosmos-sdk => github.com/bnb-chain/bnc-cosmos-sdk v0.25.10-0.20230302082041-d3ff7da93954
github.com/tendermint/go-amino => github.com/bnb-chain/bnc-go-amino v0.14.1-binance.2
github.com/tendermint/iavl => github.com/bnb-chain/bnc-tendermint-iavl v0.12.0-binance.5
github.com/tendermint/tendermint => github.com/bnb-chain/bnc-tendermint v0.32.3-bc.9
github.com/zondax/ledger-cosmos-go => github.com/bnb-chain/ledger-cosmos-go v0.9.10-0.20230201065744-d644bede1667
github.com/zondax/ledger-go => github.com/bnb-chain/ledger-go v0.9.1
golang.org/x/crypto => github.com/tendermint/crypto v0.0.0-20190823183015-45b1026d81ae
)
Loading

0 comments on commit 94936f2

Please sign in to comment.