better error message

This commit is contained in:
jb-alvarado 2023-12-05 07:30:46 +01:00
parent cf28b2b19d
commit 5c14b895f2
3 changed files with 12 additions and 6 deletions

8
Cargo.lock generated
View File

@ -1226,7 +1226,7 @@ checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5"
[[package]]
name = "ffplayout"
version = "0.20.1"
version = "0.20.2"
dependencies = [
"chrono",
"clap",
@ -1248,7 +1248,7 @@ dependencies = [
[[package]]
name = "ffplayout-api"
version = "0.20.1"
version = "0.20.2"
dependencies = [
"actix-files",
"actix-multipart",
@ -1287,7 +1287,7 @@ dependencies = [
[[package]]
name = "ffplayout-lib"
version = "0.20.1"
version = "0.20.2"
dependencies = [
"chrono",
"crossbeam-channel",
@ -3425,7 +3425,7 @@ dependencies = [
[[package]]
name = "tests"
version = "0.20.1"
version = "0.20.2"
dependencies = [
"chrono",
"crossbeam-channel",

View File

@ -4,7 +4,7 @@ default-members = ["ffplayout-api", "ffplayout-engine", "tests"]
resolver = "2"
[workspace.package]
version = "0.20.1"
version = "0.20.2"
license = "GPL-3.0"
repository = "https://github.com/ffplayout/ffplayout"
authors = ["Jonathan Baecker <jonbae77@gmail.com>"]

View File

@ -272,7 +272,13 @@ impl MediaProbe {
video_streams: v_stream,
})
}
Err(e) => Err(ProcError::Ffprobe(e)),
Err(e) => {
if !Path::new(input).is_file() {
Err(ProcError::Custom(format!("File '{input}' not exist!")))
} else {
Err(ProcError::Ffprobe(e))
}
}
}
}
}