Source code for typed_settings.exceptions
"""
Exceptions raised by Typed Settings.
"""
[docs]
class UnknownFormatError(TsError):
"""
Raised when no file format loader is configured for a given config file.
"""
[docs]
class ConfigFileNotFoundError(TsError):
"""
Raised when a mandatory config file does not exist.
"""
[docs]
class ConfigFileLoadError(TsError):
"""
Raised when a config file exists but cannot be read or parsed/loaded.
"""
[docs]
class InvalidOptionsError(TsError):
"""
Raised when loaded settings contain an option that is not defined in the
settings class.
"""
[docs]
class InvalidValueError(TsError):
"""
Raised the value of an option cannot be converted to the correct type.
"""
[docs]
class InvalidSettingsError(TsError):
"""
Raised when the loaded settings cannot be converted to an instances of the
settings class.
"""