fix : fix the conflicts
This commit is contained in:
parent
cf0be98f9b
commit
fd59a37798
@ -2,15 +2,16 @@ package gql
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/cosmos/cosmos-sdk/client"
|
||||
"os"
|
||||
"os/exec"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/client"
|
||||
)
|
||||
|
||||
// NodeDataPath is the path to the ethermintd data folder.
|
||||
var NodeDataPath = os.ExpandEnv("$HOME/.ethermintd/data")
|
||||
var NodeDataPath = os.ExpandEnv("$HOME/.chibaclonkd/data")
|
||||
|
||||
func getStatusInfo(client client.Context) (*NodeInfo, *SyncInfo, *ValidatorInfo, error) {
|
||||
nodeClient, err := client.GetNode()
|
||||
@ -48,17 +49,17 @@ func getNetInfo(client client.Context) (string, []*PeerInfo, error) {
|
||||
return "", nil, err
|
||||
}
|
||||
|
||||
peers := netInfo.Peers
|
||||
peersInfo := make([]*PeerInfo, len(peers))
|
||||
for index, peer := range peers {
|
||||
peersInfo := make([]*PeerInfo, netInfo.NPeers)
|
||||
// TODO: find a way to get the peer information from nodeClient
|
||||
for index, peer := range netInfo.Peers {
|
||||
peersInfo[index] = &PeerInfo{
|
||||
Node: &NodeInfo{
|
||||
ID: string(peer.NodeInfo.ID()),
|
||||
Moniker: peer.NodeInfo.Moniker,
|
||||
Network: peer.NodeInfo.Network,
|
||||
ID: string(peer.ID),
|
||||
// Moniker: peer.Node.Moniker,
|
||||
// Network: peer.Node.Network,
|
||||
},
|
||||
IsOutbound: peer.IsOutbound,
|
||||
RemoteIP: peer.RemoteIP,
|
||||
// IsOutbound: peer.IsOutbound,
|
||||
// RemoteIP: peer.RemoteIP,
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -61,9 +61,12 @@ func (s *IntegrationTestSuite) createAccountWithBalance(accountName string, acco
|
||||
info, _, err := val.ClientCtx.Keyring.NewMnemonic(accountName, keyring.English, sdk.FullFundraiserPath, keyring.DefaultBIP39Passphrase, hd.EthSecp256k1)
|
||||
sr.NoError(err)
|
||||
|
||||
val.ClientCtx.Keyring.SavePubKey(accountName, info.GetPubKey(), hd.EthSecp256k1Type)
|
||||
pubKey, err := info.GetPubKey()
|
||||
sr.NoError(err)
|
||||
|
||||
newAddr := sdk.AccAddress(info.GetPubKey().Address())
|
||||
val.ClientCtx.Keyring.SaveOfflineKey(accountName, pubKey)
|
||||
|
||||
newAddr, _ := info.GetAddress()
|
||||
_, err = banktestutil.MsgSendExec(
|
||||
val.ClientCtx,
|
||||
val.Address,
|
||||
|
@ -3,7 +3,7 @@ package testutil
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/types/rest"
|
||||
"github.com/cosmos/cosmos-sdk/testutil/rest"
|
||||
auctiontypes "github.com/tharsis/ethermint/x/auction/types"
|
||||
)
|
||||
|
||||
|
@ -7,12 +7,12 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/codec"
|
||||
storetypes "github.com/cosmos/cosmos-sdk/store/types"
|
||||
sdk "github.com/cosmos/cosmos-sdk/types"
|
||||
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
|
||||
auth "github.com/cosmos/cosmos-sdk/x/auth/keeper"
|
||||
bank "github.com/cosmos/cosmos-sdk/x/bank/keeper"
|
||||
params "github.com/cosmos/cosmos-sdk/x/params/types"
|
||||
|
||||
"github.com/tharsis/ethermint/x/auction/types"
|
||||
|
||||
wnsUtils "github.com/tharsis/ethermint/utils"
|
||||
@ -43,7 +43,7 @@ type Keeper struct {
|
||||
// Track auction usage in other cosmos-sdk modules (more like a usage tracker).
|
||||
usageKeepers []types.AuctionUsageKeeper
|
||||
|
||||
storeKey sdk.StoreKey // Unexposed key to access store from sdk.Context
|
||||
storeKey storetypes.StoreKey // Unexposed key to access store from sdk.Context
|
||||
|
||||
cdc codec.BinaryCodec // The wire codec for binary encoding/decoding.
|
||||
|
||||
@ -58,7 +58,7 @@ type AuctionClientKeeper interface {
|
||||
}
|
||||
|
||||
// NewKeeper creates new instances of the auction Keeper
|
||||
func NewKeeper(accountKeeper auth.AccountKeeper, bankKeeper bank.Keeper, storeKey sdk.StoreKey, cdc codec.BinaryCodec, ps params.Subspace) Keeper {
|
||||
func NewKeeper(accountKeeper auth.AccountKeeper, bankKeeper bank.Keeper, storeKey storetypes.StoreKey, cdc codec.BinaryCodec, ps params.Subspace) Keeper {
|
||||
if !ps.HasKeyTable() {
|
||||
ps = ps.WithKeyTable(types.ParamKeyTable())
|
||||
}
|
||||
|
@ -2,8 +2,9 @@ package testutil
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli"
|
||||
"github.com/cosmos/cosmos-sdk/types/rest"
|
||||
"github.com/cosmos/cosmos-sdk/testutil/rest"
|
||||
tmcli "github.com/tendermint/tendermint/libs/cli"
|
||||
"github.com/tharsis/ethermint/x/bond/client/cli"
|
||||
bondtypes "github.com/tharsis/ethermint/x/bond/types"
|
||||
|
@ -89,7 +89,7 @@ func (s *IntegrationTestSuite) createAccountWithBalance(accountName string) {
|
||||
info, _, err := val.ClientCtx.Keyring.NewMnemonic(accountName, keyring.English, sdk.FullFundraiserPath, keyring.DefaultBIP39Passphrase, hd.Secp256k1)
|
||||
sr.NoError(err)
|
||||
|
||||
newAddr := sdk.AccAddress(info.GetPubKey().Address())
|
||||
newAddr, _ := info.GetAddress()
|
||||
_, err = banktestutil.MsgSendExec(
|
||||
val.ClientCtx,
|
||||
val.Address,
|
||||
|
@ -4,7 +4,9 @@ import (
|
||||
"crypto/sha256"
|
||||
"encoding/hex"
|
||||
"fmt"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/codec"
|
||||
storetypes "github.com/cosmos/cosmos-sdk/store/types"
|
||||
sdk "github.com/cosmos/cosmos-sdk/types"
|
||||
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
|
||||
auth "github.com/cosmos/cosmos-sdk/x/auth/keeper"
|
||||
@ -29,7 +31,7 @@ type Keeper struct {
|
||||
// Track bond usage in other cosmos-sdk modules (more like a usage tracker).
|
||||
usageKeepers []types.BondUsageKeeper
|
||||
|
||||
storeKey sdk.StoreKey
|
||||
storeKey storetypes.StoreKey
|
||||
|
||||
cdc codec.BinaryCodec
|
||||
|
||||
@ -37,7 +39,7 @@ type Keeper struct {
|
||||
}
|
||||
|
||||
// NewKeeper creates new instances of the bond Keeper
|
||||
func NewKeeper(cdc codec.BinaryCodec, accountKeeper auth.AccountKeeper, bankKeeper bank.Keeper, usageKeepers []types.BondUsageKeeper, storeKey sdk.StoreKey, ps paramtypes.Subspace) Keeper {
|
||||
func NewKeeper(cdc codec.BinaryCodec, accountKeeper auth.AccountKeeper, bankKeeper bank.Keeper, usageKeepers []types.BondUsageKeeper, storeKey storetypes.StoreKey, ps paramtypes.Subspace) Keeper {
|
||||
// set KeyTable if it has not already been set
|
||||
if !ps.HasKeyTable() {
|
||||
ps = ps.WithKeyTable(types.ParamKeyTable())
|
||||
|
@ -8,8 +8,8 @@ import (
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/client/flags"
|
||||
clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli"
|
||||
"github.com/cosmos/cosmos-sdk/testutil/rest"
|
||||
sdk "github.com/cosmos/cosmos-sdk/types"
|
||||
"github.com/cosmos/cosmos-sdk/types/rest"
|
||||
tmcli "github.com/tendermint/tendermint/libs/cli"
|
||||
"github.com/tharsis/ethermint/x/nameservice/client/cli"
|
||||
nstypes "github.com/tharsis/ethermint/x/nameservice/types"
|
||||
|
@ -78,7 +78,7 @@ func (s *IntegrationTestSuite) createAccountWithBalance(accountName string) {
|
||||
sr.NoError(err)
|
||||
|
||||
// account key
|
||||
newAddr := sdk.AccAddress(info.GetPubKey().Address())
|
||||
newAddr, _ := info.GetAddress()
|
||||
_, err = banktestutil.MsgSendExec(
|
||||
val.ClientCtx,
|
||||
val.Address,
|
||||
|
@ -8,6 +8,7 @@ import (
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/codec"
|
||||
"github.com/cosmos/cosmos-sdk/codec/legacy"
|
||||
storetypes "github.com/cosmos/cosmos-sdk/store/types"
|
||||
sdk "github.com/cosmos/cosmos-sdk/types"
|
||||
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
|
||||
auth "github.com/cosmos/cosmos-sdk/x/auth/keeper"
|
||||
@ -63,7 +64,7 @@ type Keeper struct {
|
||||
bondKeeper bondkeeper.Keeper
|
||||
auctionKeeper auctionkeeper.Keeper
|
||||
|
||||
storeKey sdk.StoreKey // Unexposed key to access store from sdk.Context
|
||||
storeKey storetypes.StoreKey // Unexposed key to access store from sdk.Context
|
||||
|
||||
cdc codec.BinaryCodec // The wire codec for binary encoding/decoding.
|
||||
|
||||
@ -72,7 +73,7 @@ type Keeper struct {
|
||||
|
||||
// NewKeeper creates new instances of the nameservice Keeper
|
||||
func NewKeeper(cdc codec.BinaryCodec, accountKeeper auth.AccountKeeper, bankKeeper bank.Keeper, recordKeeper RecordKeeper,
|
||||
bondKeeper bondkeeper.Keeper, auctionKeeper auctionkeeper.Keeper, storeKey sdk.StoreKey, ps paramtypes.Subspace) Keeper {
|
||||
bondKeeper bondkeeper.Keeper, auctionKeeper auctionkeeper.Keeper, storeKey storetypes.StoreKey, ps paramtypes.Subspace) Keeper {
|
||||
// set KeyTable if it has not already been set
|
||||
if !ps.HasKeyTable() {
|
||||
ps = ps.WithKeyTable(types.ParamKeyTable())
|
||||
|
@ -5,6 +5,7 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/codec"
|
||||
storetypes "github.com/cosmos/cosmos-sdk/store/types"
|
||||
sdk "github.com/cosmos/cosmos-sdk/types"
|
||||
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
|
||||
auctionkeeper "github.com/tharsis/ethermint/x/auction/keeper"
|
||||
@ -16,7 +17,7 @@ import (
|
||||
// RecordKeeper exposes the bare minimal read-only API for other modules.
|
||||
type RecordKeeper struct {
|
||||
auctionKeeper auctionkeeper.Keeper
|
||||
storeKey sdk.StoreKey // Unexposed key to access store from sdk.Context
|
||||
storeKey storetypes.StoreKey // Unexposed key to access store from sdk.Context
|
||||
cdc codec.BinaryCodec // The wire codec for binary encoding/decoding.
|
||||
}
|
||||
|
||||
@ -123,7 +124,7 @@ func (k Keeper) RemoveBondToRecordIndexEntry(ctx sdk.Context, bondID string, id
|
||||
}
|
||||
|
||||
// NewRecordKeeper creates new instances of the nameservice RecordKeeper
|
||||
func NewRecordKeeper(auctionKeeper auctionkeeper.Keeper, storeKey sdk.StoreKey, cdc codec.BinaryCodec) RecordKeeper {
|
||||
func NewRecordKeeper(auctionKeeper auctionkeeper.Keeper, storeKey storetypes.StoreKey, cdc codec.BinaryCodec) RecordKeeper {
|
||||
return RecordKeeper{
|
||||
auctionKeeper: auctionKeeper,
|
||||
storeKey: storeKey,
|
||||
|
Loading…
Reference in New Issue
Block a user