Closed
Description
Currently, the meta-schemas for (at least) drafts 3, 4, 6, and 7 contain the following:
Lines 139 to 144 in 4e016d9
However, the prose specification says:
The value of this [i.e. the "enum"] keyword MUST be an array.
This array SHOULD have at least one element. Elements in the array SHOULD be unique.
Validation therefore ought to allow schema authors to use empty or non-unique arrays, because the RFC 2119 definition of SHOULD
explicitly permits ignoring such clauses after considering the circumstances. Alternatively, the specification could replace SHOULD
with MUST
for the relevant constraints.
Possibly related to #618? First reported at python-jsonschema/jsonschema#529, via hypothesis-jsonschema
.