-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.ReadDefaultValuesFromDefaultClientConfig
aligns with the PR's objective to ensure the--home
flag is correctly respected by reading default values from the default client configuration. This approach should effectively address the issue with the--home
flag not being respected.simapp/simd/cmd/root.go (1)
- 111-111: Replacing
config.CreateClientConfig
withconfig.ReadDefaultValuesFromDefaultClientConfig
inroot.go
is consistent with the PR's goal to fix the--home
flag issue. This modification ensures that default values are correctly read and applied, addressing the initialization problem.client/config/config.go (2)
- 39-39: Deprecating
ReadFromClientConfig
in favor of more explicit configuration handling functions is a good practice for clarity and maintainability.- 44-61: The implementation of
ReadDefaultValuesFromDefaultClientConfig
correctly addresses the issue with the--home
flag by temporarily settingHomeDir
to ensure the default client configuration is read without affecting the actualHomeDir
setting. This approach is effective for initializing the client context with default values while respecting the--home
flag.
(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 <[email protected]>
Co-authored-by: Julien Robert <[email protected]>
Co-authored-by: Julien Robert <[email protected]>
Co-authored-by: Julien Robert <[email protected]>
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.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
ReadFromClientConfig
in favor ofCreateClientConfig
for improved configuration management.ReadDefaultValuesFromDefaultClientConfig
to streamline reading default configuration values.root.go
androot_v2.go
to utilize new configuration reading approach.