Skip to content

Commit 2a066d7

Browse files
committed
client: mention to restart the node after init validator
1 parent a546c4e commit 2a066d7

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

apps/src/lib/client/tx.rs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ use namada::ledger::governance::storage as gov_storage;
1515
use namada::ledger::rpc::{TxBroadcastData, TxResponse};
1616
use namada::ledger::signing::TxSigningKey;
1717
use namada::ledger::wallet::{Wallet, WalletUtils};
18-
use namada::ledger::{masp, tx};
18+
use namada::ledger::{masp, pos, tx};
19+
use namada::proof_of_stake::parameters::PosParams;
1920
use namada::proto::{Code, Data, Section, Tx};
2021
use namada::types::address::Address;
2122
use namada::types::governance::{
@@ -305,6 +306,11 @@ pub async fn submit_init_validator<
305306
)
306307
.unwrap();
307308

309+
let key = pos::params_key();
310+
let pos_params = rpc::query_storage_value::<C, PosParams>(client, &key)
311+
.await
312+
.expect("Pos parameter should be defined.");
313+
308314
println!();
309315
println!(
310316
"The validator's addresses and keys were stored in the wallet:"
@@ -316,6 +322,11 @@ pub async fn submit_init_validator<
316322
"The ledger node has been setup to use this validator's address \
317323
and consensus key."
318324
);
325+
println!(
326+
"Your validator will be active in {} epochs. Be sure to restart \
327+
your node for the changes to take effect!",
328+
pos_params.pipeline_len
329+
);
319330
} else {
320331
println!("Transaction dry run. No addresses have been saved.")
321332
}

0 commit comments

Comments
 (0)