@@ -172,6 +172,7 @@ type EVMD struct {
172
172
keys map [string ]* storetypes.KVStoreKey
173
173
tkeys map [string ]* storetypes.TransientStoreKey
174
174
memKeys map [string ]* storetypes.MemoryStoreKey
175
+ okeys map [string ]* storetypes.ObjectStoreKey
175
176
176
177
// keepers
177
178
AccountKeeper authkeeper.AccountKeeper
@@ -267,6 +268,8 @@ func NewExampleApp(
267
268
bApp .SetVersion (version .Version )
268
269
bApp .SetInterfaceRegistry (interfaceRegistry )
269
270
bApp .SetTxEncoder (txConfig .TxEncoder ())
271
+ bApp .SetTxExecutor (DefaultTxExecutor )
272
+ bApp .SetDisableBlockGasMeter (true )
270
273
271
274
// initialize the Cosmos EVM application configuration
272
275
if err := evmAppOptions (evmChainID ); err != nil {
@@ -284,7 +287,8 @@ func NewExampleApp(
284
287
evmtypes .StoreKey , feemarkettypes .StoreKey , erc20types .StoreKey , precisebanktypes .StoreKey ,
285
288
)
286
289
287
- tkeys := storetypes .NewTransientStoreKeys (paramstypes .TStoreKey , evmtypes .TransientKey , feemarkettypes .TransientKey )
290
+ tkeys := storetypes .NewTransientStoreKeys (paramstypes .TStoreKey )
291
+ okeys := storetypes .NewObjectStoreKeys (banktypes .ObjectStoreKey , evmtypes .ObjectStoreKey , feemarkettypes .ObjectStoreKey )
288
292
289
293
// load state streaming if enabled
290
294
if err := bApp .RegisterStreamingServices (appOpts , keys ); err != nil {
@@ -305,6 +309,7 @@ func NewExampleApp(
305
309
interfaceRegistry : interfaceRegistry ,
306
310
keys : keys ,
307
311
tkeys : tkeys ,
312
+ okeys : okeys ,
308
313
}
309
314
310
315
app .ParamsKeeper = initParamsKeeper (appCodec , legacyAmino , keys [paramstypes .StoreKey ], tkeys [paramstypes .TStoreKey ])
@@ -332,6 +337,7 @@ func NewExampleApp(
332
337
333
338
app .BankKeeper = bankkeeper .NewBaseKeeper (
334
339
appCodec ,
340
+ okeys [banktypes .ObjectStoreKey ],
335
341
runtime .NewKVStoreService (keys [banktypes .StoreKey ]),
336
342
app .AccountKeeper ,
337
343
evmdconfig .BlockedAddresses (),
@@ -464,7 +470,7 @@ func NewExampleApp(
464
470
app .FeeMarketKeeper = feemarketkeeper .NewKeeper (
465
471
appCodec , authtypes .NewModuleAddress (govtypes .ModuleName ),
466
472
keys [feemarkettypes .StoreKey ],
467
- tkeys [feemarkettypes .TransientKey ],
473
+ okeys [feemarkettypes .ObjectStoreKey ],
468
474
)
469
475
470
476
// Set up PreciseBank keeper
@@ -483,7 +489,7 @@ func NewExampleApp(
483
489
// NOTE: it's required to set up the EVM keeper before the ERC-20 keeper, because it is used in its instantiation.
484
490
app .EVMKeeper = evmkeeper .NewKeeper (
485
491
// TODO: check why this is not adjusted to use the runtime module methods like SDK native keepers
486
- appCodec , keys [evmtypes .StoreKey ], tkeys [evmtypes .TransientKey ], keys ,
492
+ appCodec , keys [evmtypes .StoreKey ], okeys [evmtypes .ObjectStoreKey ], keys ,
487
493
authtypes .NewModuleAddress (govtypes .ModuleName ),
488
494
app .AccountKeeper ,
489
495
app .PreciseBankKeeper ,
@@ -751,6 +757,7 @@ func NewExampleApp(
751
757
// initialize stores
752
758
app .MountKVStores (keys )
753
759
app .MountTransientStores (tkeys )
760
+ app .MountObjectStores (okeys )
754
761
755
762
maxGasWanted := cast .ToUint64 (appOpts .Get (srvflags .EVMMaxTxGasWanted ))
756
763
0 commit comments