Skip to content

Commit e4df864

Browse files
committed
array_contains and array_find: Clarify that giving null as value always returns false or null respectively, also fixed the incorrect examples. #348
1 parent f4d5d03 commit e4df864

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3333
- Clarified that a `TargetDimensionExists` exception is thrown if the target dimension exists.
3434
- `apply` and `array_apply`: Fixed broken references to the `absolute` process
3535
- `apply_neighborhood`: Parameter `overlap` was optional but had no default value and no schena for the default value defined.
36+
- `array_contains` and `array_find`: Clarify that giving `null` as `value` always returns `false` or `null` respectively, also fixed the incorrect examples. [#348](https://github.com/Open-EO/openeo-processes/issues/348)
3637
- `array_interpolate_linear`: Return value was incorrectly specified as `number` or `null`. It must return an array instead. [#333](https://github.com/Open-EO/openeo-processes/issues/333)
3738
- `rename_labels`: Clarified that the `LabelsNotEnumerated` exception is thrown if `source` is empty instead of if `target` is empty. [#321](https://github.com/Open-EO/openeo-processes/issues/321)
3839
- `round`: Clarify that the rounding for ties applies not only for integers. [#326](https://github.com/Open-EO/openeo-processes/issues/326)

array_contains.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
},
2121
{
2222
"name": "value",
23-
"description": "Value to find in `data`.",
23+
"description": "Value to find in `data`. If the value is `null`, this process returns always `false`.",
2424
"schema": {
2525
"description": "Any data type is allowed."
2626
}
@@ -75,7 +75,7 @@
7575
],
7676
"value": null
7777
},
78-
"returns": true
78+
"returns": false
7979
},
8080
{
8181
"arguments": {
@@ -167,4 +167,4 @@
167167
"result": true
168168
}
169169
}
170-
}
170+
}

array_find.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
{
2121
"name": "value",
22-
"description": "Value to find in `data`.",
22+
"description": "Value to find in `data`. If the value is `null`, this process returns always `null`.",
2323
"schema": {
2424
"description": "Any data type is allowed."
2525
}
@@ -106,7 +106,7 @@
106106
],
107107
"value": null
108108
},
109-
"returns": 1
109+
"returns": null
110110
},
111111
{
112112
"arguments": {
@@ -168,4 +168,4 @@
168168
"title": "Find no-data values in arrays"
169169
}
170170
]
171-
}
171+
}

0 commit comments

Comments
 (0)