diff --git a/app/ante.go b/app/ante.go index 04d3c2037..83860b199 100644 --- a/app/ante.go +++ b/app/ante.go @@ -12,7 +12,6 @@ import ( govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" ibcante "github.com/cosmos/ibc-go/v7/modules/core/ante" ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" - "github.com/skip-mev/block-sdk/block" auctionanteskip "github.com/skip-mev/block-sdk/x/auction/ante" auctionkeeperskip "github.com/skip-mev/block-sdk/x/auction/keeper" ) @@ -31,7 +30,6 @@ type HandlerOptions struct { TxDecoder sdk.TxDecoder TxEncoder sdk.TxEncoder auctionkeeperskip auctionkeeperskip.Keeper - FreeLane block.Lane } func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { @@ -60,10 +58,7 @@ func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { ante.NewTxTimeoutHeightDecorator(), ante.NewValidateMemoDecorator(options.AccountKeeper), ante.NewConsumeGasForTxSizeDecorator(options.AccountKeeper), - block.NewIgnoreDecorator( - ante.NewDeductFeeDecorator(options.AccountKeeper, options.BankKeeper, options.FeegrantKeeper, options.TxFeeChecker), - options.FreeLane, - ), + ante.NewDeductFeeDecorator(options.AccountKeeper, options.BankKeeper, options.FeegrantKeeper, options.TxFeeChecker), // SetPubKeyDecorator must be called before all signature verification decorators ante.NewSetPubKeyDecorator(options.AccountKeeper), ante.NewValidateSigCountDecorator(options.AccountKeeper), diff --git a/app/app.go b/app/app.go index 90d7ca3e6..1835cab96 100644 --- a/app/app.go +++ b/app/app.go @@ -1269,14 +1269,14 @@ func New( reflectionv1.RegisterReflectionServiceServer(app.GRPCQueryRouter(), reflectionSvc) // STEP 1-3: Create the Block SDK lanes. - mevLane, freeLane, defaultLane := CreateLanes(app) + mevLane, defaultLane := CreateLanes(app) // STEP 4: Construct a mempool based off the lanes. Note that the order of the lanes // matters. Blocks are constructed from the top lane to the bottom lane. The top lane // is the first lane in the array and the bottom lane is the last lane in the array. mempool, err := block.NewLanedMempool( app.Logger(), - []block.Lane{mevLane, freeLane, defaultLane}, + []block.Lane{mevLane, defaultLane}, ) if err != nil { panic(err) @@ -1306,7 +1306,6 @@ func New( TxDecoder: encoding.TxConfig.TxDecoder(), TxEncoder: encoding.TxConfig.TxEncoder(), auctionkeeperskip: app.AuctionKeeperSkip, - FreeLane: freeLane, }, ) if err != nil { @@ -1322,9 +1321,6 @@ func New( mevLane.WithOptions( opt..., ) - freeLane.WithOptions( - opt..., - ) defaultLane.WithOptions( opt..., ) diff --git a/app/lanes.go b/app/lanes.go index 25086a920..20d98d6e6 100644 --- a/app/lanes.go +++ b/app/lanes.go @@ -6,7 +6,6 @@ import ( signerextraction "github.com/skip-mev/block-sdk/adapters/signer_extraction_adapter" "github.com/skip-mev/block-sdk/block/base" defaultlane "github.com/skip-mev/block-sdk/lanes/base" - freelane "github.com/skip-mev/block-sdk/lanes/free" mevlane "github.com/skip-mev/block-sdk/lanes/mev" ) @@ -14,7 +13,7 @@ import ( // we create three separate lanes - MEV, Free, and Default - and then return them. // // NOTE: Application Developers should closely replicate this function in their own application. -func CreateLanes(app *App) (*mevlane.MEVLane, *base.BaseLane, *base.BaseLane) { +func CreateLanes(app *App) (*mevlane.MEVLane, *base.BaseLane) { // 1. Create the signer extractor. This is used to extract the expected signers from // a transaction. Each lane can have a different signer extractor if needed. signerAdapter := signerextraction.NewDefaultAdapter() @@ -33,18 +32,7 @@ func CreateLanes(app *App) (*mevlane.MEVLane, *base.BaseLane, *base.BaseLane) { Logger: app.Logger(), TxEncoder: encodingConfig.TxConfig.TxEncoder(), TxDecoder: encodingConfig.TxConfig.TxDecoder(), - MaxBlockSpace: math.LegacyMustNewDecFromStr("0.2"), - SignerExtractor: signerAdapter, - MaxTxs: 0, - } - - // Create a free configuration that accepts 1000 transactions and consumes 20% of the - // block space. - freeConfig := base.LaneConfig{ - Logger: app.Logger(), - TxEncoder: encodingConfig.TxConfig.TxEncoder(), - TxDecoder: encodingConfig.TxConfig.TxDecoder(), - MaxBlockSpace: math.LegacyMustNewDecFromStr("0.2"), + MaxBlockSpace: math.LegacyMustNewDecFromStr("0.1"), SignerExtractor: signerAdapter, MaxTxs: 0, } @@ -55,7 +43,7 @@ func CreateLanes(app *App) (*mevlane.MEVLane, *base.BaseLane, *base.BaseLane) { Logger: app.Logger(), TxEncoder: encodingConfig.TxConfig.TxEncoder(), TxDecoder: encodingConfig.TxConfig.TxDecoder(), - MaxBlockSpace: math.LegacyMustNewDecFromStr("0.6"), + MaxBlockSpace: math.LegacyMustNewDecFromStr("0.9"), SignerExtractor: signerAdapter, MaxTxs: 0, } @@ -68,7 +56,6 @@ func CreateLanes(app *App) (*mevlane.MEVLane, *base.BaseLane, *base.BaseLane) { mevMatchHandler := factory.MatchHandler() // Create the final match handler for the free lane. - freeMatchHandler := freelane.DefaultMatchHandler() // Create the final match handler for the default lane. defaultMatchHandler := base.DefaultMatchHandler() @@ -80,16 +67,10 @@ func CreateLanes(app *App) (*mevlane.MEVLane, *base.BaseLane, *base.BaseLane) { mevMatchHandler, ) - freeLane := freelane.NewFreeLane( - freeConfig, - base.DefaultTxPriority(), - freeMatchHandler, - ) - defaultLane := defaultlane.NewDefaultLane( defaultConfig, defaultMatchHandler, ) - return mevLane, freeLane, defaultLane + return mevLane, defaultLane } diff --git a/app/upgrades/testnet/v14/upgrades.go b/app/upgrades/testnet/v14/upgrades.go index 2237e2616..aacd6a6dd 100644 --- a/app/upgrades/testnet/v14/upgrades.go +++ b/app/upgrades/testnet/v14/upgrades.go @@ -49,9 +49,9 @@ func setDefaultMEVParams(ctx sdk.Context, auctionkeeperskip auctionkeeperskip.Ke // Skip MEV (x/auction) return auctionkeeperskip.SetParams(ctx, auctionmoduleskiptypes.Params{ MaxBundleSize: auctionmoduleskiptypes.DefaultMaxBundleSize, - EscrowAccountAddress: authtypes.NewModuleAddress(auctionmoduleskiptypes.ModuleName), - ReserveFee: sdk.NewCoin(nativeDenom, sdk.NewInt(1)), - MinBidIncrement: sdk.NewCoin(nativeDenom, sdk.NewInt(1)), + EscrowAccountAddress: authtypes.NewModuleAddress(auctionmoduleskiptypes.ModuleName), // TODO: revisit + ReserveFee: sdk.NewCoin(nativeDenom, sdk.NewInt(10)), + MinBidIncrement: sdk.NewCoin(nativeDenom, sdk.NewInt(5)), FrontRunningProtection: auctionmoduleskiptypes.DefaultFrontRunningProtection, ProposerFee: auctionmoduleskiptypes.DefaultProposerFee, })