Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/ibc proto migration #5704

Closed
wants to merge 62 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
e59c32d
proto: remove cdc from ICS05
fedekunze Feb 26, 2020
6ef884f
proto: start ICS07 proto files
fedekunze Feb 26, 2020
85cc953
proto: ICS20 types
fedekunze Feb 26, 2020
d172449
proto: ICS07 messages
fedekunze Feb 26, 2020
796fe70
proto: ICS04 messages
fedekunze Feb 26, 2020
8a38c3e
proto: various ICS proto definitions
fedekunze Feb 26, 2020
a1c9ae0
proto: fixes
fedekunze Feb 26, 2020
fad6b52
godocs for ICS 07 proto file
fedekunze Feb 27, 2020
8b83fb1
proto: generate files
fedekunze Feb 27, 2020
43e38d6
merge ICS23 changes
fedekunze Mar 2, 2020
d574210
merge ibc-alpha changes
fedekunze Mar 23, 2020
5510c34
ibc: protobuf changes
fedekunze Mar 23, 2020
2d251e4
codec: move ibc client proto interfaces
fedekunze Mar 23, 2020
fc70c2e
ibc: fix some msgs and types
fedekunze Mar 23, 2020
8da8960
proto: cycles and other fixes
fedekunze Mar 24, 2020
0db08a3
proto: changes and fixes
fedekunze Mar 24, 2020
5a5816f
update types
fedekunze Mar 24, 2020
fa84a19
merge ibc-alpha changes
fedekunze Mar 24, 2020
ff66afb
fix dep cycle
fedekunze Mar 25, 2020
dfe061d
codec/std: add msgs
fedekunze Mar 25, 2020
3475fca
commitment: proto changes
fedekunze Mar 25, 2020
ee12807
fix dep cycle with Status and Order
fedekunze Mar 25, 2020
daf8f01
add tmtypes proto3 to third party
fedekunze Mar 25, 2020
ccdb13b
fixes fixes fixes
fedekunze Mar 27, 2020
94a62ca
revert GetDestination{Channel.Port}
fedekunze Mar 27, 2020
01d4651
cleanup
fedekunze Mar 27, 2020
934a576
fixes
fedekunze Mar 27, 2020
a4749e3
util funcs for tm <-> proto
fedekunze Mar 27, 2020
ea46b7f
more cleanup
fedekunze Mar 27, 2020
cff3c94
more util funcs
fedekunze Mar 30, 2020
c8229a3
more fixes
fedekunze Mar 30, 2020
610fafc
Merge branch 'ibc-alpha' of https://github.com/cosmos/cosmos-sdk into…
fedekunze Mar 31, 2020
ced1d63
more test fixes
fedekunze Mar 31, 2020
077a13f
fixes
fedekunze Mar 31, 2020
554de2d
remove PacketData and PacketAck interfaces
fedekunze Apr 1, 2020
ba1cb08
FINALLY! build
fedekunze Apr 1, 2020
2ecbb5b
fix some tests
fedekunze Apr 1, 2020
c5d00b5
fix more tests
fedekunze Apr 1, 2020
8b3400f
lint
fedekunze Apr 2, 2020
3c38a61
proto cleanup
fedekunze Apr 2, 2020
048b8d1
Merge branch 'ibc-alpha' of https://github.com/cosmos/cosmos-sdk into…
fedekunze Apr 2, 2020
2614026
try fix ics07 errors
fedekunze Apr 2, 2020
5079c78
lint
fedekunze Apr 2, 2020
80ec515
merge ibc-alpha
fedekunze Apr 3, 2020
cced361
Merge branch 'ibc-alpha' of https://github.com/cosmos/cosmos-sdk into…
fedekunze Apr 3, 2020
48828f0
Merge branch 'ibc-alpha' of github.com:cosmos/cosmos-sdk into fedekun…
fedekunze Apr 3, 2020
773a6ec
merge tm-proto
fedekunze Apr 6, 2020
9bd476f
fixes
fedekunze Apr 6, 2020
99cab85
minor updates
fedekunze Apr 7, 2020
bc0f744
merge ibc-alpha changes
fedekunze Apr 8, 2020
9dd94c0
update proto files
fedekunze Apr 8, 2020
c8669df
build
fedekunze Apr 8, 2020
f8d64c8
updates from downstream
fedekunze Apr 14, 2020
0d62302
update proto deps
fedekunze Apr 14, 2020
524cce4
fix ics07 test
fedekunze Apr 14, 2020
e5d4641
changes from master
fedekunze Apr 16, 2020
dd9df29
fix build
fedekunze Apr 16, 2020
6dac284
test fixes
fedekunze Apr 16, 2020
4d3058a
updates from downstream
fedekunze Apr 21, 2020
1b7b9c8
fixes
fedekunze Apr 21, 2020
e422b08
proto ics09
fedekunze Apr 21, 2020
8d794fa
changes from master
fedekunze Apr 29, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
updates from downstream
  • Loading branch information
fedekunze committed Apr 21, 2020
commit 4d3058ac2fc29a9dd4e9709b7114e7e757ab4965
5 changes: 4 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ proto-update-deps:
@curl -sSL $(TM_URL)/proto/types/types.proto > $(TM_PROTO)/types/types.proto
@curl -sSL $(TM_URL)/proto/types/params.proto > $(TM_PROTO)/types/params.proto
@sed -i '' '8 s|proto/libs/bits/types.proto|third_party/proto/tendermint/proto/libs/bits/types.proto|g' $(TM_PROTO)/types/types.proto
@sed -i '' '9 s|proto/crypto/keys/types.proto|third_party/proto/tendermint/proto/crypto/keys/types.proto|g' $(TM_PROTO)/types/types.proto
@sed -i '' '9 s|proto/version/version.proto|third_party/proto/tendermint/proto/version/version.proto|g' $(TM_PROTO)/types/types.proto

@curl -sSL $(TM_URL)/proto/types/evidence.proto > $(TM_PROTO)/types/evidence.proto
@sed -i '' '7 s|proto/types/types.proto|third_party/proto/tendermint/proto/types/types.proto|g' $(TM_PROTO)/types/evidence.proto
Expand All @@ -310,6 +310,9 @@ proto-update-deps:
@mkdir -p $(TM_PROTO)/crypto/keys
@curl -sSL $(TM_URL)/proto/crypto/keys/types.proto > $(TM_PROTO)/crypto/keys/types.proto

@mkdir -p $(TM_PROTO)/version
@curl -sSL $(TM_URL)/proto/version/version.proto > $(TM_PROTO)/version/version.proto

@mkdir -p $(TM_KV_TYPES)
@curl -sSL $(TM_URL)/libs/kv/types.proto > $(TM_KV_TYPES)/types.proto

Expand Down
547 changes: 273 additions & 274 deletions codec/std/codec.pb.go

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions third_party/proto/tendermint/proto/types/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ option go_package = "github.com/tendermint/tendermint/proto/types";
import "third_party/proto/gogoproto/gogo.proto";
import "google/protobuf/timestamp.proto";
import "third_party/proto/tendermint/proto/libs/bits/types.proto";
import "third_party/proto/tendermint/proto/version/version.proto";

// BlockIdFlag indicates which BlcokID the signature is for
enum BlockIDFlag {
Expand Down
3 changes: 2 additions & 1 deletion x/ibc/03-connection/keeper/verify_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (

clientexported "github.com/cosmos/cosmos-sdk/x/ibc/02-client/exported"
"github.com/cosmos/cosmos-sdk/x/ibc/03-connection/types"
channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/04-channel/types"
commitmenttypes "github.com/cosmos/cosmos-sdk/x/ibc/23-commitment/types"
ibctypes "github.com/cosmos/cosmos-sdk/x/ibc/types"
)
Expand Down Expand Up @@ -303,7 +304,7 @@ func (suite *KeeperTestSuite) TestVerifyPacketAcknowledgement() {

tc.malleate()
connection := suite.chainA.createConnection(testConnectionIDA, testConnectionIDB, testClientIDA, testClientIDB, ibctypes.OPEN)
suite.chainA.App.IBCKeeper.ChannelKeeper.SetPacketAcknowledgement(suite.chainA.GetContext(), testPort1, testChannel1, 1, ack)
suite.chainA.App.IBCKeeper.ChannelKeeper.SetPacketAcknowledgement(suite.chainA.GetContext(), testPort1, testChannel1, 1, channeltypes.CommitAcknowledgement(ack))
suite.chainB.updateClient(suite.chainA)

// TODO check this proof height
Expand Down
2 changes: 2 additions & 0 deletions x/ibc/04-channel/types/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ func RegisterCodec(cdc *codec.Codec) {
cdc.RegisterConcrete(MsgChannelCloseInit{}, "ibc/channel/MsgChannelCloseInit", nil)
cdc.RegisterConcrete(MsgChannelCloseConfirm{}, "ibc/channel/MsgChannelCloseConfirm", nil)
cdc.RegisterConcrete(MsgPacket{}, "ibc/channel/MsgPacket", nil)
cdc.RegisterConcrete(MsgAcknowledgement{}, "ibc/channel/MsgAcknowledgement", nil)
cdc.RegisterConcrete(MsgTimeout{}, "ibc/channel/MsgTimeout", nil)
}

var (
Expand Down
6 changes: 3 additions & 3 deletions x/ibc/07-tendermint/types/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ func RegisterCodec(cdc *codec.Codec) {
cdc.RegisterConcrete(ConsensusState{}, "ibc/client/tendermint/ConsensusState", nil)
cdc.RegisterConcrete(Header{}, "ibc/client/tendermint/Header", nil)
cdc.RegisterConcrete(Evidence{}, "ibc/client/tendermint/Evidence", nil)
cdc.RegisterConcrete(MsgCreateClient{}, "ibc/client/MsgCreateClient", nil)
cdc.RegisterConcrete(MsgUpdateClient{}, "ibc/client/MsgUpdateClient", nil)
cdc.RegisterConcrete(MsgSubmitClientMisbehaviour{}, "ibc/client/MsgSubmitClientMisbehaviour", nil)
cdc.RegisterConcrete(MsgCreateClient{}, "ibc/client/tendermint/MsgCreateClient", nil)
cdc.RegisterConcrete(MsgUpdateClient{}, "ibc/client/tendermint/MsgUpdateClient", nil)
cdc.RegisterConcrete(MsgSubmitClientMisbehaviour{}, "ibc/client/tendermint/MsgSubmitClientMisbehaviour", nil)
}

var (
Expand Down
1 change: 1 addition & 0 deletions x/ibc/07-tendermint/types/test_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (

"github.com/tendermint/tendermint/crypto/tmhash"
tmproto "github.com/tendermint/tendermint/proto/types"
"github.com/tendermint/tendermint/proto/version"
tmtypes "github.com/tendermint/tendermint/types"
)

Expand Down
4 changes: 3 additions & 1 deletion x/ibc/07-tendermint/types/types.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions x/ibc/07-tendermint/types/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,11 @@ message MsgSubmitClientMisbehaviour {
];
}

// ClientState defines a Tendermint consensus light client state.
// ClientState from Tendermint tracks the current validator set, latest height,
// and a possible frozen height.
message ClientState {
option (gogoproto.goproto_getters) = false;

// client id
string id = 1 [(gogoproto.customname) = "ID"];
// duration of the period since the LastestTimestamp during which the submitted
// headers are valid for upgrade
Expand Down
1 change: 1 addition & 0 deletions x/ibc/20-transfer/handler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import (
"github.com/cosmos/cosmos-sdk/codec"
"github.com/cosmos/cosmos-sdk/simapp"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/x/bank"
connectiontypes "github.com/cosmos/cosmos-sdk/x/ibc/03-connection/types"
channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/04-channel/types"
ibctmtypes "github.com/cosmos/cosmos-sdk/x/ibc/07-tendermint/types"
Expand Down
1 change: 1 addition & 0 deletions x/ibc/20-transfer/keeper/relay_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"fmt"

sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/x/bank"
channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/04-channel/types"
"github.com/cosmos/cosmos-sdk/x/ibc/20-transfer/types"
ibctypes "github.com/cosmos/cosmos-sdk/x/ibc/types"
Expand Down
1 change: 0 additions & 1 deletion x/ibc/20-transfer/types/expected_keepers.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
connection "github.com/cosmos/cosmos-sdk/x/ibc/03-connection"
channelexported "github.com/cosmos/cosmos-sdk/x/ibc/04-channel/exported"
channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/04-channel/types"
supplyexported "github.com/cosmos/cosmos-sdk/x/supply/exported"
)

// AccountKeeper defines the contract required for account APIs.
Expand Down
126 changes: 60 additions & 66 deletions x/ibc/20-transfer/types/types.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 3 additions & 9 deletions x/ibc/20-transfer/types/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@ message MsgTransfer {
(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress"
];
// the recipient address on the destination chain
bytes receiver = 6 [
(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress"
];
string receiver = 6;
}

// FungibleTokenPacketData defines a struct for the packet payload
Expand All @@ -45,13 +43,9 @@ message FungibleTokenPacketData {
(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"
];
// the sender address
bytes sender = 2 [
(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress"
];
string sender = 2;
// the recipient address on the destination chain
bytes receiver = 3 [
(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress"
];
string receiver = 3;
}

// FungibleTokenPacketAcknowledgement contains a boolean success flag and an optional error msg
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.