Coverage for src/iptvtools/exceptions.py: 75%
4 statements
« prev ^ index » next coverage.py v7.6.10, created at 2025-01-31 13:48 +0000
« prev ^ index » next coverage.py v7.6.10, created at 2025-01-31 13:48 +0000
1#!/usr/bin/env python
2"""Custom exceptions for iptvtools.
4File: exceptions.py
5Author: huxuan
6Email: i(at)huxuan.org
7"""
10class BaseCustomException(RuntimeError):
11 """Base Custom Exception."""
14class FFmpegNotInstalledError(BaseCustomException):
15 """Raise when FFmpeg is not installed."""
17 def __init__(self) -> None:
18 """Init for FfmpegNotInstalledError."""
19 super().__init__(
20 "Need `FFmpeg` for resolution related processing.\n"
21 "Please install it according to "
22 "`https://www.ffmpeg.org/download.html`."
23 )