diff --git a/CHANGELOG.md b/CHANGELOG.md index f70afe7b..60a5aa22 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,10 +9,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed - `clip`: Throw an exception if min > max [#472](https://github.com/Open-EO/openeo-processes/issues/472) +- Added a uniqueness contraint to various array-typed parameters (e.g. lists of dimension names or labels) ### Fixed - Clarified for various mathematical functions the defined input and output ranges. Mention that `NaN` is returned outside of the defined input range where possible. +- `aggregate_temporal` and `aggregate_temporal_period`: Clarified that the process throws a `DimensionNotAvailable` exception when no temporal dimension exists. - `divide`: Clarified behavior for division by 0 - `between`: Clarify that `null` is passed through. - `eq` and `neq`: Explicitly set the minimum value for the `delta` parameter. diff --git a/aggregate_temporal.json b/aggregate_temporal.json index ad1d560b..2c66e0f2 100644 --- a/aggregate_temporal.json +++ b/aggregate_temporal.json @@ -128,6 +128,7 @@ "description": "Distinct labels for the intervals, which can contain dates and/or times. Is only required to be specified if the values for the start of the temporal intervals are not distinct and thus the default labels would not be unique. The number of labels and the number of groups need to be equal.", "schema": { "type": "array", + "uniqueItems": true, "items": { "type": [ "number", @@ -140,7 +141,7 @@ }, { "name": "dimension", - "description": "The name of the temporal dimension for aggregation. All data along the dimension is passed through the specified reducer. If the dimension is not set or set to `null`, the data cube is expected to only have one temporal dimension. Fails with a `TooManyDimensions` exception if it has more dimensions. Fails with a `DimensionNotAvailable` exception if the specified dimension does not exist.", + "description": "The name of the temporal dimension for aggregation. All data along the dimension is passed through the specified reducer. If the dimension is not set or set to `null`, the data cube is expected to only have one temporal dimension. Fails with a `TooManyDimensions` exception if it has more dimensions. Fails with a `DimensionNotAvailable` exception if the specified dimension does not exist or no temporal dimension is available.", "schema": { "type": [ "string", @@ -228,7 +229,7 @@ "message": "The data cube contains multiple temporal dimensions. The parameter `dimension` must be specified." }, "DimensionNotAvailable": { - "message": "A dimension with the specified name does not exist." + "message": "A dimension with the specified name does not exist or no temporal dimension is available." }, "DistinctDimensionLabelsRequired": { "message": "The dimension labels have duplicate values. Distinct labels must be specified." diff --git a/aggregate_temporal_period.json b/aggregate_temporal_period.json index bdaea43e..ce6d4be5 100644 --- a/aggregate_temporal_period.json +++ b/aggregate_temporal_period.json @@ -78,7 +78,7 @@ }, { "name": "dimension", - "description": "The name of the temporal dimension for aggregation. All data along the dimension is passed through the specified reducer. If the dimension is not set or set to `null`, the source data cube is expected to only have one temporal dimension. Fails with a `TooManyDimensions` exception if it has more dimensions. Fails with a `DimensionNotAvailable` exception if the specified dimension does not exist.", + "description": "The name of the temporal dimension for aggregation. All data along the dimension is passed through the specified reducer. If the dimension is not set or set to `null`, the source data cube is expected to only have one temporal dimension. Fails with a `TooManyDimensions` exception if it has more dimensions. Fails with a `DimensionNotAvailable` exception if the specified dimension does not exist or no temporal dimension is available.", "schema": { "type": [ "string", @@ -115,7 +115,7 @@ "message": "The data cube contains multiple temporal dimensions. The parameter `dimension` must be specified." }, "DimensionNotAvailable": { - "message": "A dimension with the specified name does not exist." + "message": "A dimension with the specified name does not exist or no temporal dimension is available." }, "DistinctDimensionLabelsRequired": { "message": "The dimension labels have duplicate values. Distinct labels must be specified." diff --git a/proposals/array_create_labeled.json b/proposals/array_create_labeled.json index 8b5d2034..f83d6559 100644 --- a/proposals/array_create_labeled.json +++ b/proposals/array_create_labeled.json @@ -19,6 +19,7 @@ "description": "An array of labels to be used.", "schema": { "type": "array", + "uniqueItems": true, "items": { "type": [ "number", @@ -43,4 +44,4 @@ "message": "The number of values in the parameters `data` and `labels` don't match." } } -} \ No newline at end of file +} diff --git a/proposals/flatten_dimensions.json b/proposals/flatten_dimensions.json index da3647ab..1c02bf39 100644 --- a/proposals/flatten_dimensions.json +++ b/proposals/flatten_dimensions.json @@ -20,6 +20,7 @@ "description": "The names of the dimension to combine. The order of the array defines the order in which the dimension labels and values are combined (see the example in the process description). Fails with a `DimensionNotAvailable` exception if at least one of the specified dimensions does not exist.", "schema": { "type": "array", + "uniqueItems": true, "items": { "type": "string" } diff --git a/proposals/predict_curve.json b/proposals/predict_curve.json index 479b7fec..ef3e9596 100644 --- a/proposals/predict_curve.json +++ b/proposals/predict_curve.json @@ -68,6 +68,7 @@ }, { "type": "array", + "uniqueItems": true, "items": { "anyOf": [ { diff --git a/proposals/unflatten_dimension.json b/proposals/unflatten_dimension.json index 990e7469..a5a4bb6d 100644 --- a/proposals/unflatten_dimension.json +++ b/proposals/unflatten_dimension.json @@ -27,6 +27,7 @@ "description": "The names of the new target dimensions. New dimensions will be created with the given names and type `other` (see ``add_dimension()``). Fails with a `TargetDimensionExists` exception if any of the dimensions exists.\n\nThe order of the array defines the order in which the dimensions and dimension labels are added to the data cube (see the example in the process description).", "schema": { "type": "array", + "uniqueItems": true, "minItems": 2, "items": { "type": "string" diff --git a/rename_labels.json b/rename_labels.json index 2042737d..de4f07da 100644 --- a/rename_labels.json +++ b/rename_labels.json @@ -26,6 +26,7 @@ "description": "The new names for the labels.\n\nIf a target dimension label already exists in the data cube, a `LabelExists` exception is thrown.", "schema": { "type": "array", + "uniqueItems": true, "items": { "type": [ "number", @@ -39,6 +40,7 @@ "description": "The original names of the labels to be renamed to corresponding array elements in the parameter `target`. It is allowed to only specify a subset of labels to rename, as long as the `target` and `source` parameter have the same length. The order of the labels doesn't need to match the order of the dimension labels in the data cube. By default, the array is empty so that the dimension labels in the data cube are expected to be enumerated.\n\nIf the dimension labels are not enumerated and the given array is empty, the `LabelsNotEnumerated` exception is thrown. If one of the source dimension labels doesn't exist, the `LabelNotAvailable` exception is thrown.", "schema": { "type": "array", + "uniqueItems": true, "items": { "type": [ "number",