forked from cerc-io/laconicd
- Add nitro server and x/nitro module
- wire go-nitro p2p through cometbft
- Add distsig server, currently WIP
- integrate DKG and DSS schemes into ABCI methods
- Remove deprecated features
- crisis module
- module invariants
- Update to use newer SDK patterns
- upgrade sdk to v0.53.x
- custom address codec
- expand use of depinject
- migrate e2e tests to system tests
- use depinject to set up integration tests
- change reserved protobuf field name `cerc.registry.v1.Record.type`
- Revise & add documentation
- TransferCoinsToModuleAccount: clarify function
- Update init.sh script
37 lines
918 B
Go
37 lines
918 B
Go
package server
|
|
|
|
import (
|
|
"context"
|
|
|
|
"cosmossdk.io/core/gas"
|
|
sdk "github.com/cosmos/cosmos-sdk/types"
|
|
)
|
|
|
|
var _ gas.Service = gasService{}
|
|
|
|
// Placeholder gas service, in anticipation of future use
|
|
// https://github.com/cosmos/cosmos-sdk/pull/16310
|
|
type gasService struct{}
|
|
|
|
func NewGasService() gas.Service { return gasService{} }
|
|
|
|
func (gasService) GetGasMeter(ctx context.Context) gas.Meter {
|
|
c := sdk.UnwrapSDKContext(ctx)
|
|
return c.GasMeter()
|
|
}
|
|
|
|
func (gasService) WithGasMeter(ctx context.Context, meter gas.Meter) context.Context {
|
|
c := sdk.UnwrapSDKContext(ctx)
|
|
return c.WithGasMeter(meter)
|
|
}
|
|
|
|
// deprecated https://github.com/cosmos/cosmos-sdk/issues/19793
|
|
func (gasService) GetBlockGasMeter(context.Context) gas.Meter {
|
|
return nil
|
|
}
|
|
|
|
// deprecated https://github.com/cosmos/cosmos-sdk/issues/19793
|
|
func (gasService) WithBlockGasMeter(ctx context.Context, meter gas.Meter) context.Context {
|
|
return ctx
|
|
}
|