Show More
@@ -37,11 +37,11 b' def validate(nbjson):' | |||||
37 | schema_json = json.load(fh) |
|
37 | schema_json = json.load(fh) | |
38 |
|
38 | |||
39 | # resolve internal references |
|
39 | # resolve internal references | |
40 |
|
|
40 | schema = resolve_ref(schema_json) | |
41 |
|
|
41 | schema = jsonpointer.resolve_pointer(schema, '/notebook') | |
42 |
|
42 | |||
43 | # count how many errors there are |
|
43 | # count how many errors there are | |
44 |
v = Draft |
|
44 | v = Draft4Validator(schema) | |
45 | errors = list(v.iter_errors(nbjson)) |
|
45 | errors = list(v.iter_errors(nbjson)) | |
46 | return errors |
|
46 | return errors | |
47 |
|
47 |
General Comments 0
You need to be logged in to leave comments.
Login now