Ensure we log error details on failure.
It turns out that Display for anyhow::Error only gives the top-level
message, omitting the root cause(s). This is unhelpful when trying to
diagnose problems.
Before:
E pvm_exec: pvm_exec: Binder call failed
After:
E pvm_exec: pvm_exec: Binder call failed
E pvm_exec:
E pvm_exec: Caused by:
E pvm_exec: Status(-8, EX_SERVICE_SPECIFIC): '-1: Compilation failed: Status(-8,
EX_SERVICE_SPECIFIC): '-1: mount_and_wait failed: Time out mounting authfs''
Bug: 186126194
Test: Presubmit
Change-Id: Ib1c0cd7f523a75f3f98fb190843de79248c7bb96
diff --git a/microdroid_manager/src/main.rs b/microdroid_manager/src/main.rs
index 319ca2b..dc72c95 100644
--- a/microdroid_manager/src/main.rs
+++ b/microdroid_manager/src/main.rs
@@ -90,7 +90,7 @@
fn main() {
if let Err(e) = try_main() {
- error!("failed with {}", e);
+ error!("failed with {:?}", e);
std::process::exit(1);
}
}