Skip to content

Commit

Permalink
docs: Improve error message on client startup
Browse files Browse the repository at this point in the history
dashboard might fail to start if the client is still initializing. This
commit adds that information to error messages if the dashboard fails to
connect to the client.
  • Loading branch information
Sword-Smith committed May 22, 2024
1 parent 2ca4558 commit 167b452
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/bin/neptune-dashboard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ async fn main() -> Result<()> {
Ok(transp) => transp,
Err(err) => {
eprintln!("{err}");
bail!("Connection to neptune-core failed. Is a node running?");
bail!(
"Connection to neptune-core failed. Is a node running? Or is the client still \
starting up?"
);
}
};
let client = RPCClient::new(client::Config::default(), transport).spawn();
Expand All @@ -49,7 +52,10 @@ async fn main() -> Result<()> {
Ok(nw) => nw,
Err(err) => {
eprintln!("{err}");
bail!("Could not ping neptune-core. Do configurations match?");
bail!(
"Could not ping neptune-core. Do configurations match? Or is the client still \
starting up?"
);
}
};

Expand Down

0 comments on commit 167b452

Please sign in to comment.