chore(x/staking): revert proto breakage#21666
Conversation
|
Warning Rate limit exceeded@julienrbrt has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 21 minutes and 22 seconds before requesting another review. How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. WalkthroughWalkthroughThis pull request introduces significant modifications across multiple files, primarily focusing on protocol buffer definitions related to multisig accounts and staking queries. Key changes include the removal of certain import statements, the addition of new message types for handling historical staking information, and the introduction of new data structures for validator updates. The updates reflect a restructuring of the modules to enhance functionality and accommodate new features, while also marking some existing elements as deprecated. Changes
Possibly related PRs
Suggested labels
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
There was a problem hiding this comment.
Actionable comments posted: 0
Outside diff range and nitpick comments (3)
x/staking/proto/cosmos/staking/v1beta1/staking.proto (2)
21-26: Approve addition ofHistoricalInfomessage, but note deprecation.The new
HistoricalInfomessage is well-structured and serves the purpose of storing historical validator state data. However, it's important to be aware that this message is marked as deprecated, indicating potential future removal or replacement.Consider adding a comment to clarify the reason for the deprecation and any planned migration path.
397-401: Approve addition ofValidatorUpdatesmessage, but address TODO and deprecation.The new
ValidatorUpdatesmessage serves a clear purpose of holding an array of validator update objects. However, please note:
The message is marked as deprecated, suggesting potential removal or replacement in the future. Consider adding a comment to clarify the reason and any planned migration path.
There is a TODO comment indicating that this message may be moved to a different proto package (
proto/cosmos/base) to separate modules from tendermint dependency. It would be beneficial to create a follow-up issue to track this proposed refactoring.api/cosmos/staking/v1beta1/query.pulsar.go (1)
15301-15382: Code segment looks good, but note the deprecation.The
QueryHistoricalInfoRequestandQueryHistoricalInfoResponsemessage type definitions look correct and follow the expected structure.However, note that these message types are marked as deprecated using comments. This indicates that they should not be used in new code and may be removed in a future version of the API.
Consider updating any code that uses these deprecated message types to use the recommended alternatives, if available.
Review details
Configuration used: .coderabbit.yml
Review profile: CHILL
Files ignored due to path filters (5)
api/cosmos/staking/v1beta1/query_grpc.pb.gois excluded by!**/*.pb.gox/accounts/defaults/multisig/v1/multisig.pb.gois excluded by!**/*.pb.gox/staking/types/query.pb.gois excluded by!**/*.pb.gox/staking/types/query.pb.gw.gois excluded by!**/*.pb.gw.gox/staking/types/staking.pb.gois excluded by!**/*.pb.go
Files selected for processing (4)
- api/cosmos/accounts/defaults/multisig/v1/multisig.pulsar.go (2 hunks)
- api/cosmos/staking/v1beta1/query.pulsar.go (22 hunks)
- x/staking/proto/cosmos/staking/v1beta1/query.proto (2 hunks)
- x/staking/proto/cosmos/staking/v1beta1/staking.proto (2 hunks)
Additional context used
Path-based instructions (2)
api/cosmos/accounts/defaults/multisig/v1/multisig.pulsar.go (1)
Pattern
**/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.api/cosmos/staking/v1beta1/query.pulsar.go (1)
Pattern
**/*.go: Review the Golang code for conformity with the Uber Golang style guide, highlighting any deviations.
Additional comments not posted (10)
x/staking/proto/cosmos/staking/v1beta1/query.proto (3)
115-119: LGTM, but note the deprecation.The
HistoricalInfoRPC method is correctly defined in theQueryservice. However, please be aware that it is marked as deprecated, indicating that it may be removed or replaced in future versions. Consider updating any code that relies on this method.
371-375: LGTM, but note the deprecation.The
QueryHistoricalInfoRequestmessage is correctly defined with a singleheightfield. However, please be aware that it is marked as deprecated, indicating that it may be removed or replaced in future versions. Consider updating any code that relies on this message type.
379-383: LGTM, but note the deprecation.The
QueryHistoricalInfoResponsemessage is correctly defined with a singlehistfield of typeHistoricalInfo. However, please be aware that both the message and its field are marked as deprecated, indicating that they may be removed or replaced in future versions. Consider updating any code that relies on this message type.x/staking/proto/cosmos/staking/v1beta1/staking.proto (1)
12-13: Approve addition of new imports.The new import statements for
cometbft/types/v1/types.protoandcometbft/abci/v1/types.protoare necessary to support the newly addedHistoricalInfoandValidatorUpdatesmessages. The imports are correctly specified and scoped to the required types.api/cosmos/accounts/defaults/multisig/v1/multisig.pulsar.go (1)
Line range hint
1-1: This file contains generated code and should not be manually edited.This Go code file is generated from protocol buffer definitions by protoc-gen-go-pulsar. To make changes, update the corresponding .proto files and re-generate this file. Do not manually edit this generated code.
api/cosmos/staking/v1beta1/query.pulsar.go (5)
11823-12225: Code segment looks good.The generated Protobuf code for
QueryHistoricalInfoRequestandQueryHistoricalInfoResponsemessage types looks correct and follows the expected structure. No issues found.
12680-12680: Code segment looks good.The generated Protobuf code for
QueryPoolRequestmessage type looks correct and follows the expected structure. No issues found.
13038-13038: Code segment looks good.The generated Protobuf code for
QueryPoolResponsemessage type looks correct and follows the expected structure. No issues found.
13471-13471: Code segment looks good.The generated Protobuf code for
QueryParamsRequestmessage type looks correct and follows the expected structure. No issues found.
13829-13829: Code segment looks good.The generated Protobuf code for
QueryParamsResponsemessage type looks correct and follows the expected structure. No issues found.
|
just need to add back HistoricalInfo to queryserver and autocli |
Description
ref: #21382 (comment)
Makes impossible to use latest api from main in 0.52.
Author Checklist
All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.
I have...
!in the type prefix if API or client breaking changeCHANGELOG.mdReviewers Checklist
All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.
Please see Pull Request Reviewer section in the contributing guide for more information on how to review a pull request.
I have...
Summary by CodeRabbit
New Features
Bug Fixes
Documentation