cosmos / b9-checkers-academy-draft

32 stars 40 forks source link

Examples may be outdated since generators now use gogoproto #32

Open alanwilhelm opened 2 years ago

alanwilhelm commented 2 years ago

Turorial code:

message QueryGetStoredGameRequest {
    string index = 1;
}

message QueryGetStoredGameResponse {
    StoredGame StoredGame = 1;
}

message QueryAllStoredGameRequest {
    cosmos.base.query.v1beta1.PageRequest pagination = 1;
}

message QueryAllStoredGameResponse {
    repeated StoredGame StoredGame = 1;
    cosmos.base.query.v1beta1.PageResponse pagination = 2;
}

Generated code:

message QueryGetStoredGameRequest {
      string index = 1;
}

message QueryGetStoredGameResponse {
    StoredGame storedGame = 1 [(gogoproto.nullable) = false];
}

message QueryAllStoredGameRequest {
    cosmos.base.query.v1beta1.PageRequest pagination = 1;
}

message QueryAllStoredGameResponse {
    repeated StoredGame storedGame = 1 [(gogoproto.nullable) = false];
    cosmos.base.query.v1beta1.PageResponse pagination = 2;
}

This was a little confusing until I found an issue in the Tendermint repo mentioning the change.

xavierlepretre commented 2 years ago

Which Ignite version did you use? We are about to update together the project and the tutorials that go with it.