Skip to content

Commit

Permalink
fix(base-node): use less harsh emoji for unreachable node (#4855)
Browse files Browse the repository at this point in the history
Description
---
- uses plug emoji for unreachable
- puts reachability/liveness status before randomx output

Motivation and Context
---
‼ is a little harsh looking

How Has This Been Tested?
---
Manually
  • Loading branch information
sdbondi authored Oct 27, 2022
1 parent 2cf51b8 commit 2d90e91
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions applications/tari_base_node/src/commands/command/status.rs
Original file line number Diff line number Diff line change
Expand Up @@ -130,30 +130,31 @@ impl CommandContext {
num_active_rpc_sessions, self.config.base_node.p2p.rpc_max_simultaneous_sessions
),
);
if full_log {
status_line.add_field(
"RandomX",
format!(
"#{} with flags {:?}",
self.state_machine_info.borrow().randomx_vm_cnt,
self.state_machine_info.borrow().randomx_vm_flags
),
);
}

match self.comms.listening_info().liveness_status() {
LivenessStatus::Disabled => {},
LivenessStatus::Checking => {
status_line.add("⏳️️");
},
LivenessStatus::Unreachable => {
status_line.add("‼️");
status_line.add("️🔌");
},
LivenessStatus::Live(latency) => {
status_line.add(format!("⚡️ {:.2?}", latency));
},
}

if full_log {
status_line.add_field(
"RandomX",
format!(
"#{} with flags {:?}",
self.state_machine_info.borrow().randomx_vm_cnt,
self.state_machine_info.borrow().randomx_vm_flags
),
);
}

let target = "base_node::app::status";
match output {
StatusLineOutput::StdOutAndLog => {
Expand Down

0 comments on commit 2d90e91

Please sign in to comment.