chore: log panic recovery in runTx (#17556)

This commit is contained in:
Cal Bera 2023-08-28 03:22:08 -04:00 committed by GitHub
parent bb0c866193
commit cc6511e337
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -807,6 +807,7 @@ func (app *BaseApp) runTx(mode execMode, txBytes []byte) (gInfo sdk.GasInfo, res
if r := recover(); r != nil {
recoveryMW := newOutOfGasRecoveryMiddleware(gasWanted, ctx, app.runTxRecoveryMiddleware)
err, result = processRecovery(r, recoveryMW), nil
ctx.Logger().Error("panic recovered in runTx", "err", err)
}
gInfo = sdk.GasInfo{GasWanted: gasWanted, GasUsed: ctx.GasMeter().GasConsumed()}