You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The evmOS repository provides utility functions for building an unified ante handler for EVM transactions, but currently every partner chain has to implement this handler for themselves.
Possible Solution
Maybe we can provide a capable ante handler that supports all evmOS logic being checked with some options struct to configure it. Using generics we could implement an interface to support different Apps.
Any evmOS chain could implement their EVM handler like this:
import (
sdk "github.com/cosmos/cosmos-sdk/types"
evmosevmante "github.com/evmos/os/ante/evm"
)
// newEVMAnteHandler creates the sdk.AnteHandler implementation for the EVM transactions.funcnewEVMAnteHandler(optionsHandlerOptions) sdk.AnteHandler {
returnsdk.ChainAnteDecorators(
evmosevmante.NewEVMAnteDecorator(evmosevmante.EVMHandlerOptions{
// handler fields definition here
}),
// chain specific handlers could be added here
)
}
The TODO comment in the PR suggests avoiding duplication in partner repositories by providing a shared utility or library. This issue is to track the task of implementing such a solution.
Context
The evmOS repository provides utility functions for building an unified ante handler for EVM transactions, but currently every partner chain has to implement this handler for themselves.
Possible Solution
Maybe we can provide a capable ante handler that supports all evmOS logic being checked with some options struct to configure it. Using generics we could implement an interface to support different
App
s.Any evmOS chain could implement their EVM handler like this:
The TODO comment in the PR suggests avoiding duplication in partner repositories by providing a shared utility or library. This issue is to track the task of implementing such a solution.
PR URL: #30
Comment URL: #30 (comment)
The text was updated successfully, but these errors were encountered: