aboutsummaryrefslogtreecommitdiff
path: root/src/hydrilla/builder/build.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/hydrilla/builder/build.py')
-rw-r--r--src/hydrilla/builder/build.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/hydrilla/builder/build.py b/src/hydrilla/builder/build.py
index dae5579..3503f7a 100644
--- a/src/hydrilla/builder/build.py
+++ b/src/hydrilla/builder/build.py
@@ -35,7 +35,7 @@ import jsonschema
from .. import util
-index_json_schema = util.load_schema('package_source-1.schema.json')
+index_validator = util.validator_for('package_source-1.schema.json')
class FileReferenceError(Exception):
"""
@@ -275,8 +275,8 @@ class Build:
item_list.append(new_item_obj)
- return dict([(prop, new_item_obj[prop])
- for prop in ('type', 'identifier', 'version')])
+ props_in_ref = ('type', 'identifier', 'version', 'long_name')
+ return dict([(prop, new_item_obj[prop]) for prop in props_in_ref])
def _process_index_json(self, index_obj: dict):
"""
@@ -285,7 +285,7 @@ class Build:
files and computed definitions of the source package and items defined
in it.
"""
- jsonschema.validate(index_obj, index_json_schema)
+ index_validator.validate(index_obj)
self.source_name = index_obj['source_name']