scverse / spatialdata

An open and interoperable data framework for spatial omics data
https://spatialdata.scverse.org/
BSD 3-Clause "New" or "Revised" License
207 stars 40 forks source link

ome-zarr-py labels logging still appears #400

Open LucaMarconato opened 9 months ago

LucaMarconato commented 9 months ago

This log:

no parent found for <ome_zarr.reader.Label object at 0x2a2c3d5a0>: None

which appears when reading labels from Zarr should have been disabled by the code in io_zarr.py, but somehow these logs still appear. It is confusing from the users because it seems that there is a problem when it's actually all ok. We should re-disable it.

LucaMarconato commented 9 months ago

Using this works:

import logging
logging.getLogger('ome_zarr').setLevel(logging.ERROR)

we should put this in the context manager that we are already using (which already does something similar, but that is currently broken).