Closed Yaroms closed 1 month ago
The recent updates to the Lavanet rewards and subscription modules introduce new message types, enhance RPC methods, and refine data structures. These changes streamline reward management and subscription usage tracking while improving code organization. The overall result enriches user experience and functionality, making interactions with the system more efficient and intuitive.
Files | Change Summary |
---|---|
proto/lavanet/lava/rewards/*.proto |
Replaced BasePayGenesis with BasePayWithIndex ; updated RPC methods and messages for reward queries. |
proto/lavanet/lava/subscription/*.proto |
Introduced TrackedUsage and EstimatedRewards RPC methods; added new message types for tracking subscription usage. |
scripts/protocgen.sh |
Updated file path to the versioned directory structure github.com/lavanet/lava/v2 . |
testutil/common/tester.go |
Removed the QueryRewardsProviderReward method from the Tester struct. |
x/rewards/client/cli/*.go |
Modified CLI commands to reflect new tracking functionalities instead of provider rewards. |
x/subscription/keeper/grpc_query_estimated_rewards.go |
Added EstimatedRewards method to query expected rewards based on parameters. |
x/subscription/keeper/grpc_query_tracked_usage.go |
Implemented TrackedUsage method for querying subscription usage data. |
x/subscription/types/expected_keepers.go |
Expanded EpochstorageKeeper and RewardsKeeper interfaces with new methods for improved reward and stake management. |
sequenceDiagram
participant User
participant QueryClient
participant Keeper
User->>QueryClient: Request SpecTrackedInfo
QueryClient->>Keeper: SpecTrackedInfo(req)
Keeper->>Keeper: Validate request
Keeper->>Keeper: Retrieve BasePayWithIndex
Keeper->>QueryClient: Respond with tracking info
π "In fields of green where bunnies leap,
Changes sprout, new paths we keep.
With data bright and queries clear,
We track our joys from far and near.
So hop along, letβs bounce and play,
For brighter code is here to stay!" π°β¨
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?
2β159 testsβ Β±0βββ2β159 :white_check_mark: Β±0βββ25m 51s :stopwatch: +18s ββ143 suites Β±0βββββββ0 :zzz: Β±0β ββββ7 filesββ Β±0βββββββ0 :x: Β±0β
Results for commit 8382fe7e.βΒ± Comparison against base commit c74cbc78.
:recycle: This comment has been updated with latest results.
Description
Closes: #XXXX
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 changemain
branchReviewers 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.
I have...
Summary by CodeRabbit
New Features
BasePayWithIndex
to enhance base pay management with additional metadata.TrackedUsage
to query subscription usage details.SpecTrackedInfo
to focus on detailed tracking of provider information.EstimatedRewards
method to aggregate various reward sources based on stake and subscription data.Bug Fixes
Documentation
Chores