mirror of
https://github.com/correl/openapi-core.git
synced 2024-12-01 03:00:09 +00:00
14 lines
334 B
Python
14 lines
334 B
Python
import attr
|
|
|
|
from openapi_core.exceptions import OpenAPIError
|
|
|
|
|
|
@attr.s(hash=True)
|
|
class CastError(OpenAPIError):
|
|
"""Schema cast operation error"""
|
|
value = attr.ib()
|
|
type = attr.ib()
|
|
|
|
def __str__(self):
|
|
return "Failed to cast value {value} to type {type}".format(
|
|
value=self.value, type=self.type)
|