@classmethod
    def validate_schema(cls, data, schema):
        try:
            checker = jsonschema.FormatChecker()
            jsonschema.validate(data, schema, format_checker=checker)
        except Exception as exc:
            # We need to cast a given exception to the string since it's the
            # only way to print readable validation error. Unfortunately,
            # jsonschema has no base class for exceptions, so we don't know
            # about internal attributes with error description.
            raise errors.InvalidData(str(exc))
Extract only the required fields for the create/update API call
dataset/ETHPy150Open openstack/fuel-web/nailgun/nailgun/api/v1/validators/base.py/BasicValidator.validate_schema--crossover with--dataset/ETHPy150Open boundary/pulse-api-cli/boundary/metric_export.py/MetricExport.extractFields