Skip to content
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

Miscellaneous Docs Improvements #7606

Merged
merged 10 commits into from
Oct 22, 2020
3 changes: 2 additions & 1 deletion validator/accounts/accounts_exit.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,8 @@ func interact(cliCtx *cli.Context, r io.Reader, validatingPublicKeys [][48]byte)
"Please navigate to the following website and make sure you understand the current implications " +
"of a voluntary exit before making the final decision:"
promptURL := au.Blue("https://docs.prylabs.network/docs/wallet/exiting-a-validator/#withdrawal-delay-warning")
promptQuestion := "If you still want to continue with the voluntary exit, please input the passphrase from the above URL"
promptQuestion := "If you still want to continue with the voluntary exit, please input a phrase found at the end " +
"of the page from the above URL"
promptText := fmt.Sprintf("%s\n%s\n%s\n%s", promptHeader, promptDescription, promptURL, promptQuestion)
resp, err := promptutil.ValidatePrompt(r, promptText, func(input string) error {
return promptutil.ValidatePhrase(input, exitPassphrase)
Expand Down
2 changes: 1 addition & 1 deletion validator/accounts/wallet_create.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func CreateAndSaveWalletCli(cliCtx *cli.Context) (*wallet.Wallet, error) {

w, err := CreateWalletWithKeymanager(cliCtx.Context, createWalletConfig)
if err != nil {
return nil, errors.Wrap(err, "could not create wallet with keymanager")
return nil, errors.Wrap(err, "could not create wallet")
}
return w, nil
}
Expand Down
2 changes: 1 addition & 1 deletion validator/client/validator.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func (v *validator) WaitForWalletInitialization(ctx context.Context) error {
ctx, true, /* skipMnemonicConfirm */
)
if err != nil {
return errors.Wrap(err, "could not read keymanager for wallet")
return errors.Wrap(err, "could not read keymanager")
}
v.keyManager = keyManager
return nil
Expand Down
2 changes: 1 addition & 1 deletion validator/rpc/accounts.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func (s *Server) DeleteAccounts(
return nil, status.Error(codes.InvalidArgument, "No public keys specified to delete")
}
if s.wallet == nil || s.keymanager == nil {
return nil, status.Error(codes.FailedPrecondition, "No wallet nor keymanager found")
return nil, status.Error(codes.FailedPrecondition, "No wallet found")
}
if s.wallet.KeymanagerKind() != keymanager.Imported {
return nil, status.Error(codes.FailedPrecondition, "Only imported wallets can delete accounts")
Expand Down
2 changes: 1 addition & 1 deletion validator/rpc/accounts_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ func TestServer_DeleteAccounts_FailedPreconditions(t *testing.T) {
_, err = ss.DeleteAccounts(ctx, &pb.DeleteAccountsRequest{
PublicKeys: make([][]byte, 1),
})
assert.ErrorContains(t, "No wallet nor keymanager found", err)
assert.ErrorContains(t, "No wallet found", err)
}

func TestServer_DeleteAccounts_OK(t *testing.T) {
Expand Down