-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
refactor: fetch CometInfo from service #20238
Conversation
WalkthroughWalkthroughThe recent updates across various modules in the Changes
Assessment against linked issues
Recent Review DetailsConfiguration used: .coderabbit.yml Files selected for processing (3)
Additional Context UsedLanguageTool (196)
Path-based Instructions (3)
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 as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Out of diff range and nitpick comments (2)
CHANGELOG.md (2)
43-43
: Add a blank line before the "Features" heading for proper markdown formatting.
44-44
: Add a blank line before and after the list of features for proper markdown formatting.
func (c ContextAwareCometInfoService) CometInfo(ctx context.Context) corecomet.Info { | ||
return sdk.UnwrapSDKContext(ctx).CometInfo() | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The method CometInfo
directly unwraps the SDK context to fetch CometInfo
. Consider error handling if the context cannot be unwrapped or if CometInfo
is not available.
- return sdk.UnwrapSDKContext(ctx).CometInfo()
+ sdkCtx, ok := sdk.UnwrapSDKContext(ctx)
+ if !ok {
+ return nil, fmt.Errorf("invalid context provided")
+ }
+ return sdkCtx.CometInfo(), nil
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
func (c ContextAwareCometInfoService) CometInfo(ctx context.Context) corecomet.Info { | |
return sdk.UnwrapSDKContext(ctx).CometInfo() | |
} | |
func (c ContextAwareCometInfoService) CometInfo(ctx context.Context) (corecomet.Info, error) { | |
sdkCtx, ok := sdk.UnwrapSDKContext(ctx) | |
if !ok { | |
return nil, fmt.Errorf("invalid context provided") | |
} | |
return sdkCtx.CometInfo(), nil | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Do we have tests for environment?
cometinfo shouldnt be in environment. This was avoided so we are not tying environment to a consensus protocol |
At what level would we have consensus then? In terms of accessing data |
- alias core/comet to core/abci - refactor usages of core/comet throughout SDK
After offline discussion I floated renaming core/cometinfo -> core/abciinfo since this seems more in line with the spirit of what it represents, and in actuality creates no hard dependency on cometbft libraries, it's more the abci layer. the last commit does that and refactors usages through the sdk to use core/abci instead of core/comet, but keeps the alias for backwards compat. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Out of diff range and nitpick comments (1)
baseapp/abci_utils_test.go (1)
20-20
: Consider organizing imports to improve readability.Imports should be grouped in a conventional order: standard library imports, third-party imports, and then local imports. This helps in maintaining a clean and organized codebase.
baseapp/abci_utils_test.go
Outdated
lastCommit := coreabci.CommitInfo{ | ||
Round: ec.Round, | ||
Votes: make([]comet.VoteInfo, len(ec.Votes)), | ||
Votes: make([]coreabci.VoteInfo, len(ec.Votes)), | ||
} | ||
|
||
for i, vote := range ec.Votes { | ||
lastCommit.Votes[i] = comet.VoteInfo{ | ||
Validator: comet.Validator{ | ||
lastCommit.Votes[i] = coreabci.VoteInfo{ | ||
Validator: coreabci.Validator{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tip
Codebase Verification
Several files in the codebase still lack specific tests for the extendedCommitToLastCommit
function. While general assertions are present in baseapp/abci_utils_test.go
, they do not directly address the functionality of extendedCommitToLastCommit
. It is recommended to add more targeted tests to ensure the conversion logic is thoroughly verified.
- File needing attention:
baseapp/abci_utils_test.go
: Contains general assertions but lacks direct tests forextendedCommitToLastCommit
.
Analysis chain
Ensure conversion logic correctness in extendedCommitToLastCommit
.
Consider adding more unit tests to verify the conversion logic in extendedCommitToLastCommit
, ensuring all necessary information is retained and correctly set up.
Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: Verify that the conversion from `abci.ExtendedCommitInfo` to `comet.Info` in `extendedCommitToLastCommit` function retains all necessary information and correctly sets up the `coreabci.CommitInfo`.
# Find all test files that test the `extendedCommitToLastCommit` function.
rg --files-with-matches --type go $'func Test.*extendedCommitToLastCommit' | while read file; do
# Test: Search for assertions that verify the correctness of the conversion. Expect: At least one assertion per test case.
rg 'require\.(Equal|NoError)' "$file"
done
Length of output: 87
Script:
#!/bin/bash
# Description: Search for any test files related to the `extendedCommitToLastCommit` function to verify the presence of tests.
# Search for any Go test files in the repository.
rg --files --type go '.*_test\.go$'
# Search for the presence of the function `extendedCommitToLastCommit` in the codebase to confirm its implementation.
rg --files-with-matches --type go 'func .*extendedCommitToLastCommit'
Length of output: 246
Script:
#!/bin/bash
# Description: Inspect identified test files for relevant test cases and assertions related to the `extendedCommitToLastCommit` function.
# Check for relevant test cases in 'vote_extensions_test.go'
echo "Checking vote_extensions_test.go for relevant test cases:"
rg 'func Test.*extendedCommitToLastCommit' tests/integration/staking/keeper/vote_extensions_test.go
# Check for relevant test cases in 'abci_utils_test.go'
echo "Checking abci_utils_test.go for relevant test cases:"
rg 'func Test.*extendedCommitToLastCommit' baseapp/abci_utils_test.go
# Check for assertions in these test cases
echo "Checking for assertions in identified test cases:"
rg 'require\.(Equal|NoError)' tests/integration/staking/keeper/vote_extensions_test.go
rg 'require\.(Equal|NoError)' baseapp/abci_utils_test.go
Length of output: 740
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we just need to remove it from env otherwise good
This reverts commit fb6f2a7.
- refactor appModules and Keepers
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
simapp/app.go
Outdated
@@ -281,6 +281,7 @@ func NewSimApp( | |||
interfaceRegistry: interfaceRegistry, | |||
keys: keys, | |||
} | |||
cometService := runtime.ContextAwareCometInfoService{} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Introduce CometInfoService
with proper initialization.
The CometInfoService
is instantiated but not properly initialized. It's crucial to ensure that the service is correctly set up with necessary dependencies or configurations to function as expected. Consider initializing it with required parameters or services.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
need to add changelog entries to the modules then we can merge this
Co-authored-by: Marko <marko@baricevic.me>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 4
Out of diff range and nitpick comments (3)
tests/integration/slashing/abci_test.go (1)
Line range hint
107-122
: Ensure consistent context updates within the loop.Consider refactoring the loop to update the context in a single place to enhance readability and reduce the chance of errors in context management.
for ; height < ((signedBlocksWindow * 2) - minSignedPerWindow + 1); height++ { - ctx = ctx.WithHeaderInfo(coreheader.Info{Height: height}).WithCometInfo(comet.Info{ + ctx = ctx.WithHeaderInfo(coreheader.Info{Height: height}) LastCommit: comet.CommitInfo{Votes: []comet.VoteInfo{{ Validator: abciVal, BlockIDFlag: comet.BlockIDFlagAbsent, }}}, })tests/integration/evidence/keeper/infraction_test.go (1)
Line range hint
245-258
: Handle potential errors inBeginBlocker
.- assert.NilError(t, f.evidenceKeeper.BeginBlocker(ctx.WithCometInfo(nci), cometInfoService)) + err = f.evidenceKeeper.BeginBlocker(ctx.WithCometInfo(nci), cometInfoService) + assert.NilError(t, err)This change ensures that any errors during the execution of
BeginBlocker
are caught and handled appropriately, maintaining the robustness of the test.tests/integration/slashing/keeper/keeper_test.go (1)
Line range hint
1-200
: Review of the entire test file shows that existing functionalities are maintained and the integration ofcometInfoService
does not introduce any regressions.It's recommended to add more comprehensive tests around the new
cometInfoService
to ensure all edge cases are covered.Would you like assistance in drafting additional test cases for
cometInfoService
?
cometInfoService := runtime.NewContextAwareCometInfoService() | ||
|
||
err = slashing.BeginBlocker(ctx, slashingKeeper) | ||
err = slashing.BeginBlocker(ctx, slashingKeeper, cometInfoService) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Introduce error handling for NewContextAwareCometInfoService
.
- cometInfoService := runtime.NewContextAwareCometInfoService()
+ cometInfoService, err := runtime.NewContextAwareCometInfoService()
+ require.NoError(t, err)
This change ensures that any errors during the initialization of cometInfoService
are caught and handled appropriately, maintaining the robustness of the test.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
cometInfoService := runtime.NewContextAwareCometInfoService() | |
err = slashing.BeginBlocker(ctx, slashingKeeper) | |
err = slashing.BeginBlocker(ctx, slashingKeeper, cometInfoService) | |
cometInfoService, err := runtime.NewContextAwareCometInfoService() | |
require.NoError(t, err) | |
err = slashing.BeginBlocker(ctx, slashingKeeper, cometInfoService) |
@@ -100,7 +100,7 @@ func initFixture(tb testing.TB) *fixture { | |||
authority.String(), | |||
) | |||
|
|||
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger()), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr)) | |||
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger()), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure proper error handling for NewKeeper
.
- stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger()), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService())
+ stakingKeeper, err := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger()), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService())
+ require.NoError(t, err)
This change ensures that any errors during the initialization of stakingKeeper
are caught and handled appropriately, maintaining the robustness of the test.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger()), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) | |
stakingKeeper, err := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger()), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) | |
require.NoError(t, err) |
@@ -155,7 +159,7 @@ func initFixture(tb testing.TB) *fixture { | |||
authority.String(), | |||
) | |||
|
|||
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[types.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(queryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr)) | |||
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[types.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(queryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure proper error handling for NewKeeper
.
- stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[types.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(queryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService())
+ stakingKeeper, err := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[types.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(queryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService())
+ require.NoError(t, err)
This change ensures that any errors during the initialization of stakingKeeper
are caught and handled appropriately, maintaining the robustness of the test.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[types.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(queryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) | |
stakingKeeper, err := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[types.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(queryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) | |
require.NoError(t, err) |
@@ -136,7 +137,7 @@ func initFixture(tb testing.TB) *fixture { | |||
authority.String(), | |||
) | |||
|
|||
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(grpcQueryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr)) | |||
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(grpcQueryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure proper error handling for NewKeeper
.
- stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(grpcQueryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService())
+ stakingKeeper, err := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(grpcQueryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService())
+ require.NoError(t, err)
This change ensures that any errors during the initialization of stakingKeeper
are caught and handled appropriately, maintaining the robustness of the test.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
stakingKeeper := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(grpcQueryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) | |
stakingKeeper, err := stakingkeeper.NewKeeper(cdc, runtime.NewEnvironment(runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), log.NewNopLogger(), runtime.EnvWithRouterService(grpcQueryRouter, msgRouter)), accountKeeper, bankKeeper, authority.String(), addresscodec.NewBech32Codec(sdk.Bech32PrefixValAddr), addresscodec.NewBech32Codec(sdk.Bech32PrefixConsAddr), runtime.NewContextAwareCometInfoService()) | |
require.NoError(t, err) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 7
Out of diff range and nitpick comments (1)
x/slashing/CHANGELOG.md (1)
Line range hint
44-44
: Adjust indentation for list items to match the standard markdown list style.- * remove `Keeper`: `SetValidatorSigningInfo`, `GetValidatorSigningInfo`, `IterateValidatorSigningInfos` + * remove `Keeper`: `SetValidatorSigningInfo`, `GetValidatorSigningInfo`, `IterateValidatorSigningInfos`
@@ -35,6 +35,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ | |||
|
|||
### API Breaking Changes | |||
|
|||
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure consistency in service naming.
- * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`.
+ * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. | |
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`. |
Correct the grammatical error in the sentence.
- * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`.
+ * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. | |
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`. |
@@ -35,6 +35,7 @@ | |||
|
|||
### API Breaking Changes | |||
|
|||
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. | |||
* [#20026](https://github.com/cosmos/cosmos-sdk/pull/20026) Removal of the Address.String() method and related changes: | |||
* `Migrate` now takes a `ValidatorAddressCodec` as argument. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix indentation for list items to maintain consistency.
- * `Migrate` now takes a `ValidatorAddressCodec` as argument.
- * `Migrator` has a new field of `ValidatorAddressCodec` type.
+ * `Migrate` now takes a `ValidatorAddressCodec` as argument.
+ * `Migrator` has a new field of `ValidatorAddressCodec` type.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* `Migrate` now takes a `ValidatorAddressCodec` as argument. | |
* `Migrate` now takes a `ValidatorAddressCodec` as argument. | |
* `Migrator` has a new field of `ValidatorAddressCodec` type. |
@@ -27,6 +27,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ | |||
|
|||
### Api Breaking Changes | |||
|
|||
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure consistency in service naming and correct grammatical errors.
- * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`.
+ * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. | |
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`. |
Add a space between sentences to improve readability.
- * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`.
+ * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` an argument. `BeginBlocker` now takes in a `core/comet.Service`. | |
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewAppModule` now takes in a `core/comet.Service` as an argument. `BeginBlocker` now takes in a `core/comet.Service`. |
@@ -43,6 +43,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ | |||
|
|||
### API Breaking Changes | |||
|
|||
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure consistency in service naming and correct grammatical errors.
- * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument.
+ * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument. | |
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument. |
Add a space between sentences to improve readability.
- * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument.
+ * [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument.
Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument. | |
* [#20238](https://github.com/cosmos/cosmos-sdk/pull/20238) `NewKeeper` now accepts a `core/comet.Service` as its last argument. |
Description
An alternative to #19602, and required for server v2 work, this PR:
Environment
As a big plus this removes the dependency on the SDK from x/consensus.
closes #19599
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.md
Reviewers 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
Summary by CodeRabbit