Skip to content

Commit

Permalink
add a log and update size for promptui (#13542)
Browse files Browse the repository at this point in the history
  • Loading branch information
james-prysm authored Jan 30, 2024
1 parent 224b136 commit 2581233
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions validator/accounts/accounts_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,14 @@ func selectAccounts(selectionPrompt string, pubKeys [][fieldparams.BLSPubkeyLeng
exit := "Done selecting"
results := make([]int, 0)
au := aurora.NewAurora(true)
if len(pubKeyStrings) > 5 {
log.Warnf("there are more than %d potential public keys to exit, please consider using the --%s or --%s flags", 5, flags.VoluntaryExitPublicKeysFlag.Name, flags.ExitAllFlag.Name)
}
for result != exit {
p := promptui.Select{
Label: selectionPrompt,
HideSelected: true,
Size: len(pubKeyStrings),
Items: append([]string{exit, allAccountsText}, pubKeyStrings...),
Templates: templates,
}
Expand Down

0 comments on commit 2581233

Please sign in to comment.