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

Update CCV provider protos to include MsgSubmitConsumerDoubleVoting message #112

Merged
merged 7 commits into from
Oct 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 2 additions & 0 deletions .changelog/unreleased/features/113-ccv-protos.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- Update CCV provider protos to include misbehaviour-related messages
([\#113](https://github.com/cosmos/ibc-proto-rs/issues/113))
12 changes: 6 additions & 6 deletions scripts/sync-protobuf.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,17 @@ COSMOS_ICS_GIT="${COSMOS_ICS_GIT:-$CACHE_PATH/cosmos/interchain-security.git}"

COSMOS_SDK_COMMIT="$(cat src/COSMOS_SDK_COMMIT)"
IBC_GO_COMMIT="$(cat src/IBC_GO_COMMIT)"
COSMOS_ICS_COMMIT="$(cat src/COSMOS_ICS_COMMIT)"
INTERCHAIN_SECURITY_COMMIT="$(cat src/INTERCHAIN_SECURITY_COMMIT)"

echo "COSMOS_SDK_COMMIT: $COSMOS_SDK_COMMIT"
echo "IBC_GO_COMMIT: $IBC_GO_COMMIT"
echo "COSMOS_ICS_COMMIT: $COSMOS_ICS_COMMIT"
echo "INTERCHAIN_SECURITY_COMMIT: $INTERCHAIN_SECURITY_COMMIT"

# Use either --ics-commit flag for commit ID,
# or --ics-tag for git tag. Because we can't modify
# proto-compiler to have smart detection on that.

if [[ "$COSMOS_ICS_COMMIT" =~ ^[a-zA-Z0-9]{40}$ ]]
if [[ "$INTERCHAIN_SECURITY_COMMIT" =~ ^[a-zA-Z0-9]{40}$ ]]
then
ICS_COMMIT_OPTION="--ics-commit"
else
Expand Down Expand Up @@ -111,7 +111,7 @@ COSMOS_ICS_DIR=$(mktemp -d /tmp/interchain-security-XXXXXXXX)

pushd "$COSMOS_ICS_DIR"
git clone "$COSMOS_ICS_GIT" .
git checkout -b "$COSMOS_ICS_COMMIT" "$COSMOS_ICS_COMMIT"
git checkout -b "$INTERCHAIN_SECURITY_COMMIT" "$INTERCHAIN_SECURITY_COMMIT"

cd proto
buf mod update
Expand Down Expand Up @@ -163,13 +163,13 @@ mkdir -p src/prost

cd tools/proto-compiler

cargo build --locked
cargo build

# Run the proto-compiler twice,
# once for std version with --build-tonic set to true
# and once for no-std version with --build-tonic set to false

cargo run --locked -- compile \
cargo run -- compile \
--ics "$COSMOS_ICS_DIR/proto-include" \
--sdk "$COSMOS_SDK_DIR/proto-include" \
--ibc "$IBC_GO_DIR/proto-include" \
Expand Down
1 change: 0 additions & 1 deletion src/COSMOS_ICS_COMMIT

This file was deleted.

1 change: 1 addition & 0 deletions src/INTERCHAIN_SECURITY_COMMIT
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ea545b490b53b8e6f422492b4fb2820ab0bc140b
8 changes: 3 additions & 5 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ pub const COSMOS_SDK_COMMIT: &str = include_str!("COSMOS_SDK_COMMIT");
/// The version (commit hash) of IBC Go used when generating this library.
pub const IBC_GO_COMMIT: &str = include_str!("IBC_GO_COMMIT");

/// The version (commit hash) of Interchain Security used when generating this library.
pub const INTERCHAIN_SECURITY_COMMIT: &str = include_str!("INTERCHAIN_SECURITY_COMMIT");

/// File descriptor set of compiled proto.
#[cfg(feature = "proto-descriptor")]
pub const FILE_DESCRIPTOR_SET: &[u8] = include_bytes!("prost/proto_descriptor.bin");
Expand Down Expand Up @@ -63,11 +66,6 @@ pub mod cosmos {
}
}
}
pub mod evidence {
pub mod v1beta1 {
include_proto!("cosmos.evidence.v1beta1.rs");
}
}
pub mod staking {
pub mod v1beta1 {
include_proto!("cosmos.staking.v1beta1.rs");
Expand Down
18 changes: 0 additions & 18 deletions src/prost/cosmos.evidence.v1beta1.rs

This file was deleted.

Loading
Loading