Skip to content
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

deleting a h5 group not possible #14

Open
the-hampel opened this issue Mar 13, 2023 · 0 comments
Open

deleting a h5 group not possible #14

the-hampel opened this issue Mar 13, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@the-hampel
Copy link
Member

the-hampel commented Mar 13, 2023

Deleting a h5 group with the triqs h5 python layer is not possible. Consider as a simple example the following standard dft_tools archive with the top layer content:

HDFArchive (partial view) with the following content:
  dft_input : subgroup
  dft_misc_input : subgroup
  dft_symmcorr_input : subgroup

running:

with HDFArchive('svo.h5','a') as ar:
    del ar['dft_misc_input']

is not deleting the group. The output still looks the same. However, with h5py this is possible:

import h5py
with h5py.File('svo.h5',  'a') as ar:
    del ar['dft_misc_input']

removes the group from the archive:

HDFArchive (partial view) with the following content:
  dft_input : subgroup
  dft_symmcorr_input : subgroup

I also noticed that the example given in the docstring of the h5 main class do not work:

>>> # retrieve a remove archive (in read-only mode) :

the test was done on the 1.1.x branch, but the unstable branch shows the same behavior.

@the-hampel the-hampel added the bug Something isn't working label Mar 13, 2023
@the-hampel the-hampel changed the title deleting a h5 groupt not possible deleting a h5 group not possible Mar 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant