From 9c391a08a96d9f016b6529cb79856a6cf25cc968 Mon Sep 17 00:00:00 2001 From: Ethan Buchman Date: Wed, 26 Apr 2017 01:20:29 -0400 Subject: [PATCH] fix some imports --- cmd/commands/ibc.go | 4 ++-- cmd/commands/query.go | 4 ++-- cmd/commands/tx.go | 2 +- cmd/commands/utils.go | 2 +- plugins/ibc/ibc_test.go | 8 ++++---- scripts/print_txs.go | 2 +- tests/tendermint/main.go | 2 +- types/test_helpers.go | 4 ++-- types/tx_test.go | 1 - 9 files changed, 14 insertions(+), 15 deletions(-) diff --git a/cmd/commands/ibc.go b/cmd/commands/ibc.go index bd3efe5ea8..fa6d4758cc 100644 --- a/cmd/commands/ibc.go +++ b/cmd/commands/ibc.go @@ -10,8 +10,8 @@ import ( "github.com/tendermint/basecoin/plugins/ibc" - "github.com/tendermint/merkleeyes/iavl" "github.com/tendermint/go-wire" + "github.com/tendermint/merkleeyes/iavl" tmtypes "github.com/tendermint/tendermint/types" ) @@ -229,7 +229,7 @@ func ibcPacketPostTxCmd(cmd *cobra.Command, args []string) error { } var packet ibc.Packet - proof := new(merkle.IAVLProof) + proof := new(iavl.IAVLProof) err = wire.ReadBinaryBytes(packetBytes, &packet) if err != nil { diff --git a/cmd/commands/query.go b/cmd/commands/query.go index fa96756a42..1b46a6617a 100644 --- a/cmd/commands/query.go +++ b/cmd/commands/query.go @@ -8,8 +8,8 @@ import ( "github.com/pkg/errors" "github.com/spf13/cobra" - "github.com/tendermint/merkleeyes/iavl" "github.com/tendermint/go-wire" + "github.com/tendermint/merkleeyes/iavl" tmtypes "github.com/tendermint/tendermint/types" ) @@ -202,7 +202,7 @@ func verifyCmd(cmd *cobra.Command, args []string) error { return errors.Errorf("Proof (%v) is invalid hex: %v\n", proofFlag, err) } - proof, err := merkle.ReadProof(proofBytes) + proof, err := iavl.ReadProof(proofBytes) if err != nil { return errors.Errorf("Error unmarshalling proof: %v\n", err) } diff --git a/cmd/commands/tx.go b/cmd/commands/tx.go index d8edcd08e6..0ee0896b01 100644 --- a/cmd/commands/tx.go +++ b/cmd/commands/tx.go @@ -11,7 +11,7 @@ import ( client "github.com/tendermint/tendermint/rpc/client" wire "github.com/tendermint/go-wire" - ctypes "github.com/tendermint/tendermint/rpc/core/types" + ctypes "github.com/tendermint/tendermint/rpc/tendermint/core/types" ) //commands diff --git a/cmd/commands/utils.go b/cmd/commands/utils.go index e31847a899..b0e8b2cc89 100644 --- a/cmd/commands/utils.go +++ b/cmd/commands/utils.go @@ -17,7 +17,7 @@ import ( cmn "github.com/tendermint/tmlibs/common" client "github.com/tendermint/tendermint/rpc/client" wire "github.com/tendermint/go-wire" - ctypes "github.com/tendermint/tendermint/rpc/core/types" + ctypes "github.com/tendermint/tendermint/rpc/tendermint/core/types" tmtypes "github.com/tendermint/tendermint/types" ) diff --git a/plugins/ibc/ibc_test.go b/plugins/ibc/ibc_test.go index 58c7086482..53864e62cf 100644 --- a/plugins/ibc/ibc_test.go +++ b/plugins/ibc/ibc_test.go @@ -9,12 +9,12 @@ import ( "github.com/stretchr/testify/assert" abci "github.com/tendermint/abci/types" "github.com/tendermint/basecoin/types" - cmn "github.com/tendermint/tmlibs/common" crypto "github.com/tendermint/go-crypto" - "github.com/tendermint/merkleeyes/iavl" "github.com/tendermint/go-wire" eyes "github.com/tendermint/merkleeyes/client" + "github.com/tendermint/merkleeyes/iavl" tm "github.com/tendermint/tendermint/types" + cmn "github.com/tendermint/tmlibs/common" ) // NOTE: PrivAccounts are sorted by Address, @@ -192,7 +192,7 @@ func TestIBCPlugin(t *testing.T) { Prove: true, }) assert.Nil(err) - var proof *merkle.IAVLProof + var proof *iavl.IAVLProof err = wire.ReadBinaryBytes(resQuery.Proof, &proof) assert.Nil(err) @@ -379,7 +379,7 @@ func TestIBCPluginBadProof(t *testing.T) { Prove: true, }) assert.Nil(err) - var proof *merkle.IAVLProof + var proof *iavl.IAVLProof err = wire.ReadBinaryBytes(resQuery.Proof, &proof) assert.Nil(err) diff --git a/scripts/print_txs.go b/scripts/print_txs.go index bf8ddce362..de3a2ebd9b 100644 --- a/scripts/print_txs.go +++ b/scripts/print_txs.go @@ -13,7 +13,7 @@ import ( "github.com/tendermint/tendermint/rpc/client" "github.com/tendermint/tendermint/rpc/types" "github.com/tendermint/go-wire" - _ "github.com/tendermint/tendermint/rpc/core/types" // Register RPCResponse > Result types + _ "github.com/tendermint/tendermint/rpc/tendermint/core/types" // Register RPCResponse > Result types ) func main() { diff --git a/tests/tendermint/main.go b/tests/tendermint/main.go index 137cd6c215..0d994d45eb 100644 --- a/tests/tendermint/main.go +++ b/tests/tendermint/main.go @@ -10,7 +10,7 @@ import ( "github.com/tendermint/tendermint/rpc/client" "github.com/tendermint/tendermint/rpc/types" wire "github.com/tendermint/go-wire" - _ "github.com/tendermint/tendermint/rpc/core/types" // Register RPCResponse > Result types + _ "github.com/tendermint/tendermint/rpc/tendermint/core/types" // Register RPCResponse > Result types ) func main() { diff --git a/types/test_helpers.go b/types/test_helpers.go index ccd46074ac..ffd3ce931f 100644 --- a/types/test_helpers.go +++ b/types/test_helpers.go @@ -3,8 +3,8 @@ package types // Helper functions for testing import ( - cmn "github.com/tendermint/tmlibs/common" "github.com/tendermint/go-crypto" + cmn "github.com/tendermint/tmlibs/common" ) // Creates a PrivAccount from secret. @@ -100,6 +100,6 @@ func GetTx(seq int, accOut PrivAccount, accsIn ...PrivAccount) *SendTx { func SignTx(chainID string, tx *SendTx, accs ...PrivAccount) { signBytes := tx.SignBytes(chainID) for i, _ := range tx.Inputs { - tx.Inputs[i].Signature = crypto.SignatureS{accs[i].Sign(signBytes)} + tx.Inputs[i].Signature = accs[i].Sign(signBytes) } } diff --git a/types/tx_test.go b/types/tx_test.go index 092652d1b8..79ce9b90a3 100644 --- a/types/tx_test.go +++ b/types/tx_test.go @@ -6,7 +6,6 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - cmn "github.com/tendermint/tmlibs/common" data "github.com/tendermint/go-wire/data" )