Skip to content

Commit

Permalink
Merge pull request #290 from bnb-chain/develop
Browse files Browse the repository at this point in the history
release: prepare release for v0.2.4
  • Loading branch information
randyahx authored Aug 29, 2023
2 parents b48770f + 84cc43e commit 7ff7381
Show file tree
Hide file tree
Showing 11 changed files with 195 additions and 148 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Changelog

## v0.2.4
This release includes all the changes in the v0.2.4 alpha versions and 2 new bugfixes.

Bugfixes:
* [#281](https://github.com/bnb-chain/greenfield-cosmos-sdk/pull/281) fix: disable pre deliver when raw db store is used
* [#287](https://github.com/bnb-chain/greenfield-cosmos-sdk/pull/287) fix: fix dependency security issues

Chores:
* [#289](https://github.com/bnb-chain/greenfield-cosmos-sdk/pull/289) chore: modify code comments in VerifySignature

## v0.2.4-alpha.2
This release includes 5 new features.

Expand Down
14 changes: 11 additions & 3 deletions baseapp/abci.go
Original file line number Diff line number Diff line change
Expand Up @@ -545,8 +545,10 @@ func (app *BaseApp) PreBeginBlock(req abci.RequestPreBeginBlock) (res abci.Respo
app.cms.SetTracingContext(map[string]interface{}{"blockHeight": req.Header.Height})
}

// Initialize the preDeliverTx state.
app.setPreState(req.StateNumber, req.Header)
if app.IsIavlStore() {
// Initialize the preDeliverTx state.
app.setPreState(req.StateNumber, req.Header)
}

res = abci.ResponsePrefetch{Code: abci.CodeTypeOK}
return
Expand All @@ -559,6 +561,10 @@ func (app *BaseApp) PreDeliverTx(req abci.RequestPreDeliverTx) {
}
}()

if !app.IsIavlStore() {
return
}

preState := app.preDeliverStates[req.StateIndex]
if preState == nil {
return
Expand All @@ -580,7 +586,9 @@ func (app *BaseApp) PreCommit(req abci.RequestPreCommit) (res abci.ResponsePrefe
}
}()

app.preDeliverStates[req.StateIndex].ms.Write()
if app.IsIavlStore() {
app.preDeliverStates[req.StateIndex].ms.Write()
}

res = abci.ResponsePrefetch{Code: abci.CodeTypeOK}
return
Expand Down
19 changes: 10 additions & 9 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ require (
github.com/cosmos/iavl v0.20.0
github.com/cosmos/ledger-cosmos-go v0.12.2
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0
github.com/ethereum/go-ethereum v1.10.19
github.com/ethereum/go-ethereum v1.10.26
github.com/golang/mock v1.6.0
github.com/golang/protobuf v1.5.3
github.com/google/gofuzz v1.2.0
Expand All @@ -44,7 +44,7 @@ require (
github.com/jhump/protoreflect v1.15.1
github.com/magiconair/properties v1.8.6
github.com/manifoldco/promptui v0.9.0
github.com/mattn/go-isatty v0.0.18
github.com/mattn/go-isatty v0.0.19
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.14.0
github.com/prometheus/common v0.42.0
Expand Down Expand Up @@ -96,7 +96,7 @@ require (
github.com/felixge/httpsnoop v1.0.2 // indirect
github.com/ferranbt/fastssz v0.0.0-20210905181407-59cf6761a7d5 // indirect
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/gin-gonic/gin v1.8.1 // indirect
github.com/gin-gonic/gin v1.9.1 // indirect
github.com/go-kit/kit v0.12.0 // indirect
github.com/go-kit/log v0.2.1 // indirect
github.com/go-logfmt/logfmt v0.5.1 // indirect
Expand All @@ -118,7 +118,7 @@ require (
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/jmhodges/levigo v1.0.0 // indirect
github.com/klauspost/compress v1.16.3 // indirect
github.com/klauspost/cpuid/v2 v2.0.9 // indirect
github.com/klauspost/cpuid/v2 v2.2.4 // indirect
github.com/lib/pq v1.10.7 // indirect
github.com/libp2p/go-buffer-pool v0.1.0 // indirect
github.com/linxGnu/grocksdb v1.7.16 // indirect
Expand All @@ -131,7 +131,7 @@ require (
github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect
github.com/mtibben/percent v0.2.1 // indirect
github.com/pelletier/go-toml v1.9.5 // indirect
github.com/pelletier/go-toml/v2 v2.0.7 // indirect
github.com/pelletier/go-toml/v2 v2.0.8 // indirect
github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/prometheus/client_model v0.3.0 // indirect
Expand All @@ -145,11 +145,12 @@ require (
github.com/spf13/afero v1.9.2 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/subosito/gotenv v1.4.1 // indirect
github.com/supranational/blst v0.3.8-0.20220526154634-513d2456b344 // indirect
github.com/supranational/blst v0.3.11 // indirect
github.com/thomaso-mirodin/intmath v0.0.0-20160323211736-5dc6d854e46e // indirect
github.com/urfave/cli/v2 v2.3.0 // indirect
github.com/urfave/cli/v2 v2.10.2 // indirect
github.com/wealdtech/go-bytesutil v1.1.1 // indirect
github.com/wealdtech/go-eth2-types/v2 v2.5.2 // indirect
github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect
github.com/zondax/hid v0.9.1 // indirect
github.com/zondax/ledger-go v0.14.1 // indirect
go.etcd.io/bbolt v1.3.7 // indirect
Expand All @@ -169,7 +170,7 @@ replace (
github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0
github.com/btcsuite/btcd => github.com/btcsuite/btcd v0.23.0

github.com/cometbft/cometbft => github.com/bnb-chain/greenfield-cometbft v0.0.3-alpha.1
github.com/cometbft/cometbft => github.com/bnb-chain/greenfield-cometbft v0.0.3
github.com/cometbft/cometbft-db => github.com/bnb-chain/greenfield-cometbft-db v0.8.1-alpha.1
github.com/cosmos/iavl => github.com/bnb-chain/greenfield-iavl v0.20.1

Expand All @@ -179,7 +180,7 @@ replace (
github.com/dgrijalva/jwt-go => github.com/golang-jwt/jwt/v4 v4.4.2
// Fix upstream GHSA-h395-qcrw-5vmq and GHSA-3vp4-m3rf-835h vulnerabilities.
// TODO Remove it: https://github.com/cosmos/cosmos-sdk/issues/10409
github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.0
github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.1
// replace broken goleveldb
github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7
)
Expand Down
Loading

0 comments on commit 7ff7381

Please sign in to comment.