Closed freakabcd closed 5 years ago
Reading the spec again (carefully this time), especially this part (emphasis mine):
The most basic schema is a blank JSON object, which constrains nothing, allows anything, and describes nothing:
{}
You can apply constraints on an instance by adding validation keywords to the schema. For example, the “type” keyword can be used to restrict an instance to an object, array, string, number, boolean, or null
The schema should simply be {}
without any specification of type
(which only allows the specified values of [ object, array, string, number, boolean, null ]
I'll amend the commit and push it up.
Can we comment out the pygments_css
import in server/handlers.py
? It is generating build failures due to flake8 unused import
.
@freakabcd merge upstream, it's already gone
no-change amend commit pushed to retrigger CI
Redundant since https://github.com/encode/typesystem/blob/master/typesystem/fields.py now deals with validation etc.
(And correctly uses true
for Any
.)
Don't bail out when an Any type is encountered.
According to my reading of the spec,
{}
is the type that represents Any. See the Quickstart section on http://json-schema.org/ and https://cswr.github.io/JsonSchema/spec/multiple_types/