File size: 799 Bytes
076bd51 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | class TikTokRecorderError(Exception):
"""Base exception for all TikTok Recorder errors."""
def __init__(self, message):
super().__init__(message)
class UserLiveError(TikTokRecorderError):
"""Error related to user live status."""
def __init__(self, message):
super().__init__(message)
class IPBlockedByWAF(TikTokRecorderError):
"""Raised when IP is blocked by WAF."""
def __init__(self, message="IP blocked by WAF"):
super().__init__(message)
class LiveNotFound(TikTokRecorderError):
"""Raised when a live stream is not found."""
pass
class ArgsParseError(TikTokRecorderError):
"""Raised for argument parsing errors."""
pass
class NetworkError(TikTokRecorderError):
"""Raised for network-related errors."""
pass
|