ome / omero-scripts

Core OMERO Scripts
https://pypi.org/project/omero-scripts/
12 stars 32 forks source link

Add HCS support to Remove_KeyVal.py #199

Closed will-moore closed 2 years ago

will-moore commented 2 years ago

See https://forum.image.sc/t/uploading-key-value-pairs-from-csv-files-into-omero-web-for-plates/60202/48

This adds HCS support to the Remove_KeyVal.py, extending the existing logic for Datasaets (where ALL key-value pairs on a Dataset and it's Images are deleted).

To test:

cc @abhamacher

imagesc-bot commented 2 years ago

This pull request has been mentioned on Image.sc Forum. There might be relevant details there:

https://forum.image.sc/t/uploading-key-value-pairs-from-csv-files-into-omero-web-for-plates/60202/50

abhamacher commented 2 years ago

Hi Will,

thanks for your fast implementation. I tested the script on a 96-well and a 384-well plate and it worked well on deleting the KV-pairs on wells and images. I tried it also with single images of a plate, which worked too without issues.

Now, that there are scripts for adding and deleting KV-pairs on plates, it would be lovely to have an "export all KV-pairs" too, which is available in the original KV-pair script from Chris Evenhuis for Datasets. But that has probably not the highest priority, the other two scripts were more importing from my point of view.

Thanks!

JensWendt commented 2 years ago

Hi, tried it on one plate with all 3 levels (plate, well, image) annotated. Plate was not full but only a few wells with 2 images each. Worked.

sbesson commented 2 years ago

The CI failures seem to be largely independent of this PR but it looks like GitHub Actions got (auto)disabled when https://github.com/ome/omero-scripts/pull/193 was merged while the new added script did not meet the codestyle requirement (flake8).

Available options are either to fix these issues or exclude the script e.g. via configuration.

will-moore commented 2 years ago

@sbesson I fixed all the flake8 issues with Remove_KeyVal.py, so maybe if this could be merged, then I could fix flake8 for the other scripts in a separate PR (probably in #195).

joshmoore commented 2 years ago

:+1:

sbesson commented 2 years ago

Thanks @will-moore and agreed on fixing only the warning associated with the script modified in this PR and handling the other ones separately. @joshmoore beat me to it it seems. Is it worth capturing the remaining flake8 fixes as an issue?

joshmoore commented 2 years ago

Is it worth capturing the remaining flake8 fixes as an issue?

I started to, but with #195 open (and failing) I figured it's essentially a blocker there.