fix(simapp): fix default home#19393
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 26 minutes and 57 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. WalkthroughThe recent updates to the codebase focus on enhancing the configuration management for the client by deprecating the Changes
Assessment against linked issues
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 (
|
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Review Status
Actionable comments generated: 0
Configuration used: .coderabbit.yml
Files selected for processing (3)
- client/config/config.go (1 hunks)
- simapp/simd/cmd/root.go (1 hunks)
- simapp/simd/cmd/root_v2.go (1 hunks)
Additional comments: 4
simapp/simd/cmd/root_v2.go (1)
- 123-123: The change to use
config.ReadDefaultValuesFromDefaultClientConfigaligns with the PR's objective to ensure the--homeflag is correctly respected by reading default values from the default client configuration. This approach should effectively address the issue with the--homeflag not being respected.simapp/simd/cmd/root.go (1)
- 111-111: Replacing
config.CreateClientConfigwithconfig.ReadDefaultValuesFromDefaultClientConfiginroot.gois consistent with the PR's goal to fix the--homeflag issue. This modification ensures that default values are correctly read and applied, addressing the initialization problem.client/config/config.go (2)
- 39-39: Deprecating
ReadFromClientConfigin favor of more explicit configuration handling functions is a good practice for clarity and maintainability.- 44-61: The implementation of
ReadDefaultValuesFromDefaultClientConfigcorrectly addresses the issue with the--homeflag by temporarily settingHomeDirto ensure the default client configuration is read without affecting the actualHomeDirsetting. This approach is effective for initializing the client context with default values while respecting the--homeflag.
(cherry picked from commit 72a56d9) # Conflicts: # CHANGELOG.md # client/config/config.go # simapp/simd/cmd/root.go # simapp/simd/cmd/root_v2.go
Co-authored-by: Julien Robert <julien@rbrt.fr>
Co-authored-by: Julien Robert <julien@rbrt.fr>
Co-authored-by: Julien Robert <julien@rbrt.fr>
Description
Closes: #18868
For reference, a temporary workaround, without adding this api (and thus needing 0.50.4) is this commit: b9de0f3
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.
I have...
Summary by CodeRabbit
ReadFromClientConfigin favor ofCreateClientConfigfor improved configuration management.ReadDefaultValuesFromDefaultClientConfigto streamline reading default configuration values.root.goandroot_v2.goto utilize new configuration reading approach.