-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
Since the policy schema is pretty simple, I was thinking about extracting information from the error message: if the error message is
Invalid policy definition: [] is not of type 'object'
Failed validating 'type' in schema['properties']['policy']['properties']['overrides']:
{'additionalProperties': False,
'patternProperties': {'^[a-z][-a-z_]*': {'format': 'date',
'type': 'string'}},
'type': 'object'}
On instance['policy']['overrides']:
[]
Then we have the path of the wrong object in On instance['policy']['overrides']
, and the actual and expected types in the first line. This should be sufficient to create a new error message that is friendlier to a python audience.
Originally posted by @keewis in #32 (comment)
Metadata
Metadata
Assignees
Labels
No labels