Better error reporting when ffprobe fails.
This commit is contained in:
parent
872c1096a6
commit
4ba8e3e3ee
@ -297,7 +297,7 @@ fn json_metadata_for_path<P: AsRef<Path> + AsRef<OsStr>>(path: P) -> Result<Stri
|
||||
])
|
||||
.arg(Path::new("./").join(path));
|
||||
info!(target: "json", "cmd {:?}", cmd);
|
||||
let output = cmd.output()?;
|
||||
let output = cmd.output().context(format!("failed to run {:?}", cmd))?;
|
||||
if output.status.success() {
|
||||
return Ok(String::from_utf8(output.stdout)?);
|
||||
}
|
||||
@ -617,7 +617,7 @@ impl MovieLibrary {
|
||||
Some((path.to_string_lossy().into_owned(), json))
|
||||
}
|
||||
Err(e) => {
|
||||
error!("failed to open {}: {}", path.to_string_lossy(), e);
|
||||
error!("Failed to open {}: {}", path.to_string_lossy(), e);
|
||||
None
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user