formats/v2: better error reporting for validation
This commit is contained in:
parent
062fc2a793
commit
36a5f9263a
1 changed files with 3 additions and 1 deletions
|
|
@ -392,7 +392,9 @@ def validate(manifest: Dict, index: Index) -> ValidationResult:
|
|||
result = schema.validate(manifest)
|
||||
|
||||
def validate_module(mod, klass, path):
|
||||
name = mod["type"]
|
||||
name = mod.get("type")
|
||||
if not name:
|
||||
return
|
||||
schema = index.get_schema(klass, name, version="2")
|
||||
res = schema.validate(mod)
|
||||
result.merge(res, path=path)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue