Anndata.write fails with "object header message is too large"


I’m trying to .write() an anndata object where I have a large dataframe (8869 columns) in the obsm attribute (adata.obsm["my_key"] = large_df). The write call fails with:

RuntimeError: Unable to create attribute (object header message is too large)

Above error raised while writing key 'my_key' of <class ''> to /

Any idea if and how this can be dealt with in anndata, or must we use mudata in this case?