diff --git a/CHANGELOG.md b/CHANGELOG.md index e5e0e8ac179..b33db49d7cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -94,6 +94,7 @@ Every module contains its own CHANGELOG.md. Please refer to the module you are i * (x/genutil) [#19735](https://github.com/cosmos/cosmos-sdk/pull/19735) Update genesis api to match new `appmodule.HasGenesis` interface. * (server) [#19966](https://github.com/cosmos/cosmos-sdk/pull/19966) Return BlockHeader by shallow copy in server Context. * (proto) [#20098](https://github.com/cosmos/cosmos-sdk/pull/20098) Use cosmos_proto added_in annotation instead of // Since comments. +* (baseapp) [#20208](https://github.com/cosmos/cosmos-sdk/pull/20208) Skip running validateBasic for rechecking txs. ### Bug Fixes diff --git a/baseapp/baseapp.go b/baseapp/baseapp.go index 2726a36f080..f4cb145b273 100644 --- a/baseapp/baseapp.go +++ b/baseapp/baseapp.go @@ -871,8 +871,12 @@ func (app *BaseApp) runTx(mode execMode, txBytes []byte) (gInfo sdk.GasInfo, res } msgs := tx.GetMsgs() - if err := validateBasicTxMsgs(app.msgServiceRouter, msgs); err != nil { - return sdk.GasInfo{}, nil, nil, err + // run validate basic if mode != recheck. + // as validate basic is stateless, it is guaranteed to pass recheck, given that its passed checkTx. + if mode != execModeReCheck { + if err := validateBasicTxMsgs(app.msgServiceRouter, msgs); err != nil { + return sdk.GasInfo{}, nil, nil, err + } } if app.anteHandler != nil {