Repository: fractal-analytics-platform/fractal-tasks-core (language: python)

Issue:
Write version in plate attributes
Our current converters are not writing a version in the plate .zattrs. Not sure why our validation still passes with this, but the spec specifies:

> The plate dictionary MUST contain a version key whose value MUST be a string specifying the version of the plate specification.

https://ngff.openmicroscopy.org/latest/index.html#plate-md


Discussion / hints:
> Not sure why our validation still passes with this,

I guess it's because `version` is not marked as required in the NGFF JSON Schemas (https://github.com/ome/ngff/blob/main/0.4/schemas/plate.schema#L135-L137):
```json
      "required": [
        "columns", "rows", "wells"
      ]
```
Ah, I now realised:
The 0.4 spec says it SHOULD contain a version key. Only the current latest 0.5-dev is switching this to MUST.

In any case, I think it's a really good idea that it does contain one! I'll be adding it in the 1.0 refactor now
This was implemented in https://github.com/fractal-analytics-platform/fractal-tasks-core/pull/671
We now always write the version. But our NGFF validator still has it as Optional, as it's not required in 0.4.

Fix patch:
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 236160c22..a7a79cbd1 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,6 +1,12 @@
 **Note**: Numbers like (\#123) point to closed Pull Requests on the fractal-tasks-core repository.
 
+# Unreleased
+
+* Testing
+    * Use latest version of Zenodo tiny-ome-zarr dataset (\#817).
+
 # 1.3.0
+
 * Tasks:
     * `image_glob_patterns` are renamed to `include_glob_patterns` in Convert Cellvoyager to OME-Zarr (regular & multiplexing) (\#812).
     * Convert Cellvoyager to OME-Zarr (regular & multiplexing) gain exclusion patterns to exclude specific patterns of images from being processed (\#812).
@@ -16,7 +22,7 @@
 # 1.2.1
 * Core-library
     * Add `create_roi_table_from_df_list` library function in `fractal_tasks_core.v1.roi`: It combines a list of ROI table dataframes into an AnnData ROI table and handles repeating labels (\#811).
-    * Move `create_well_acquisition_dict` & `_split_well_path_image_path` from fractal_tasks_core.tasks._registration_utils.py & fractal_tasks_core.tasks._zarr_utils into fractal_tasks_core.utils (\#811).
+    * Move `create_well_acquisition_dict` & `_split_well_path_image_path` from `fractal_tasks_core.tasks._registration_utils.py` & `fractal_tasks_core.tasks._zarr_utils` into `fractal_tasks_core.utils` (\#811).
 * Tasks:
     * Fixes issue 810 for Cellpose task: Avoids creating duplicated entries in ROI tables when masking ROI table input was used (\#811).
 


Test patch:
diff --git a/tests/tasks/conftest.py b/tests/tasks/conftest.py
index cc7c1d519..d2bcffd68 100644
--- a/tests/tasks/conftest.py
+++ b/tests/tasks/conftest.py
@@ -80,7 +80,7 @@ def zenodo_zarr(testdata_path: Path) -> list[str]:
     """
 
     # 1 Download Zarrs from Zenodo
-    DOI = "10.5281/zenodo.10257149"
+    DOI = "10.5281/zenodo.13305156"
     DOI_slug = DOI.replace("/", "_").replace(".", "_")
     platenames = ["plate.zarr", "plate_mip.zarr"]
     rootfolder = testdata_path / DOI_slug
diff --git a/tests/tasks/test_unit_copy_hcs.py b/tests/tasks/test_unit_copy_hcs.py
index b2c5f08f8..8fe3ae53f 100644
--- a/tests/tasks/test_unit_copy_hcs.py
+++ b/tests/tasks/test_unit_copy_hcs.py
@@ -32,6 +32,7 @@
         "columns": [{"name": "03"}],
         "rows": [{"name": "B"}],
         "wells": [{"columnIndex": 0, "path": "B/03", "rowIndex": 0}],
+        "version": "0.4",
     }
 }