2018-10-31 16:08:29 +00:00
|
|
|
class Pysubs2Error(Exception):
|
|
|
|
"""Base class for pysubs2 exceptions."""
|
|
|
|
|
2021-07-14 23:13:28 +00:00
|
|
|
|
2018-10-31 16:08:29 +00:00
|
|
|
class UnknownFPSError(Pysubs2Error):
|
|
|
|
"""Framerate was not specified and couldn't be inferred otherwise."""
|
|
|
|
|
2021-07-14 23:13:28 +00:00
|
|
|
|
2018-10-31 16:08:29 +00:00
|
|
|
class UnknownFileExtensionError(Pysubs2Error):
|
|
|
|
"""File extension does not pertain to any known subtitle format."""
|
|
|
|
|
2021-07-14 23:13:28 +00:00
|
|
|
|
2018-10-31 16:08:29 +00:00
|
|
|
class UnknownFormatIdentifierError(Pysubs2Error):
|
|
|
|
"""Unknown subtitle format identifier (ie. string like ``"srt"``)."""
|
|
|
|
|
2021-07-14 23:13:28 +00:00
|
|
|
|
2018-10-31 16:08:29 +00:00
|
|
|
class FormatAutodetectionError(Pysubs2Error):
|
|
|
|
"""Subtitle format is ambiguous or unknown."""
|
2020-03-08 04:49:53 +00:00
|
|
|
|
2021-07-14 23:13:28 +00:00
|
|
|
|
2020-03-08 04:49:53 +00:00
|
|
|
class ContentNotUsable(Pysubs2Error):
|
|
|
|
"""Current content not usable for specified format"""
|