chore(vcs/gerrit/ssh): add more error reporting when creating the SSH master

Otherwise, it's hard to debug.

Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
This commit is contained in:
raito 2024-12-16 00:37:07 +01:00
parent af42f93996
commit e998fabf13

View file

@ -19,7 +19,13 @@ impl GerritSSHApi {
let tempdir = builder let tempdir = builder
.launch_master(destination) .launch_master(destination)
.await .await
.unwrap_or_else(|_| panic!("Failed to launch SSH master to destination '{}'", uri)); .unwrap_or_else(|e| {
eprintln!("{e:?}");
panic!(
"Failed to launch SSH master to destination '{}' due to the previous error",
uri
)
});
Self { Self {
session: Session::new_process_mux(tempdir), session: Session::new_process_mux(tempdir),
} }