Commit aecc596c authored by Pierre Dittgen's avatar Pierre Dittgen

Remove 'duplicate-dimensions-values-labels' error check

parent e20e7f2f
Pipeline #38237 failed with stage
in 7 seconds
......@@ -291,25 +291,6 @@ def validate_dataset(dataset_dir, ignore_errors=[]):
"location": "{}/dataset.json".format(dataset_code),
})
error_code = 'duplicate-dimensions-values-labels'
dimensions_values_labels = dataset_json.get('dimensions_values_labels')
if error_code not in ignore_errors and dimensions_values_labels is not None:
for dim in dimensions_values_labels:
label_set = set()
dim_data = dimensions_values_labels[dim]
dim_dict = dim_data if isinstance(dim_data, dict) else dict(dim_data)
for label in dim_dict.values():
if label in label_set:
errors.append({
"cause": build_jsonschema_error(dataset_schema_errors),
"error_code": error_code,
"message": "Dimension label '{}' appear more than once for dimension '{}' in dataset.json".format(label, dim),
"provider_code": provider_code,
"dataset_code": dataset_code,
"location": "{}/dataset.json".format(dataset_code),
})
label_set.add(label)
return (dataset_json, dataset_series, errors)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment