Skip to content

Attributes.__delitem__ is broken #2903

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
dcherian opened this issue Mar 10, 2025 · 0 comments · Fixed by #2908
Closed

Attributes.__delitem__ is broken #2903

dcherian opened this issue Mar 10, 2025 · 0 comments · Fixed by #2908
Labels
bug Potential issues with the zarr-python library

Comments

@dcherian
Copy link
Contributor

dcherian commented Mar 10, 2025

Zarr version

v3.0.5

Description

Deleting zarr_group.attrs["key"] doesn't work.

def __delitem__(self, key: str) -> None:
new_attrs = dict(self._obj.metadata.attributes)
del new_attrs[key]
self._obj = self._obj.update_attributes(new_attrs)

After #2870 , update_attributes means update, not overwrite.

Steps to reproduce

...

Additional output

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Potential issues with the zarr-python library
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant