v3.0: fix: Show correct default path in signer error messages (backport of #7849)#7867
Closed
mergify[bot] wants to merge 1 commit intov3.0from
Closed
v3.0: fix: Show correct default path in signer error messages (backport of #7849)#7867mergify[bot] wants to merge 1 commit intov3.0from
mergify[bot] wants to merge 1 commit intov3.0from
Conversation
Fixes the problem with Solana CLI when configuration contains an invalid `keypair_path`: error messages suggest creating new keypairs at the misconfigured location instead of the user's actual default directory. This leads to confusion and keypairs being created in wrong locations. Modified error message generation in `efaultSigner::path()` to always suggest the system default path based on the user's actual home directory, regardless of any misconfigured paths in config files. (cherry picked from commit 7c3e9e7) # Conflicts: # clap-utils/src/keypair.rs # clap-v3-utils/src/keypair.rs
Author
|
Cherry-pick of 7c3e9e7 has failed: To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally |
|
i think this one is wrong too #7849 (comment) also merge conflicts need resolved |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
When Solana CLI configuration contains an invalid
keypair_path, error messages suggest creating new keypairs at the misconfigured location instead of the user's actual default directory. This leads to confusion and keypairs being created in wrong locations (e.g.,/home/sol/identity/id.jsoninstead of$HOME/.config/solana/id.json).Solution
Modified error message generation in
DefaultSigner::path()to always suggest the system default path (~/.config/solana/id.json) based on the user's actual home directory, regardless of any misconfigured paths in config files.@KirillLykov can you check this, closes #6637
This is an automatic backport of pull request #7849 done by Mergify.