"""Exception classes."""
[docs]
class APISpecError(Exception):
"""Base class for all apispec-related errors."""
[docs]
class PluginMethodNotImplementedError(APISpecError, NotImplementedError):
"""Raised when calling an unimplemented helper method in a plugin"""
[docs]
class DuplicateComponentNameError(APISpecError):
"""Raised when registering two components with the same name"""
[docs]
class DuplicateParameterError(APISpecError):
"""Raised when registering a parameter already existing in a given scope"""
[docs]
class InvalidParameterError(APISpecError):
"""Raised when parameter doesn't contains required keys"""
[docs]
class OpenAPIError(APISpecError):
"""Raised when a OpenAPI spec validation fails."""