diff --git a/cove_ofds/process.py b/cove_ofds/process.py index 182dc55..fe1fb6a 100644 --- a/cove_ofds/process.py +++ b/cove_ofds/process.py @@ -656,7 +656,16 @@ def process(self, process_data: dict) -> dict: schema = OFDSSchema() worker = AdditionalFields(schema) - context = {"additional_fields": worker.process(data)} + # Version 0.5 of lib introduces backwards incompatible changes to output; + # for now just put output back to how version 0.4 used to be. + output = worker.process(data) + output = [ + [field_info["path"], field_info["field_name"], field_info["count"]] + for field, field_info in output.items() + if field_info["root_additional_field"] + ] + + context = {"additional_fields": output} context["additional_fields_count"] = len(context["additional_fields"]) with open(self.data_filename, "w") as fp: diff --git a/requirements.txt b/requirements.txt index c9b92a1..f50fe6d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -50,7 +50,7 @@ jsonref==0.2 # libcoveofds jsonschema==4.17.0 # via libcoveofds -libcoveofds==0.4.0 +libcoveofds==0.5.0 # via -r requirements.in lxml==4.9.1 # via flattentool diff --git a/requirements_dev.txt b/requirements_dev.txt index b206af6..0aea382 100644 --- a/requirements_dev.txt +++ b/requirements_dev.txt @@ -97,7 +97,7 @@ jsonschema==4.17.0 # via # -r requirements.txt # libcoveofds -libcoveofds==0.4.0 +libcoveofds==0.5.0 # via -r requirements.txt libsass==0.21.0 # via -r requirements_dev.in