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

Add unsafe open mode #79

Merged
merged 10 commits into from
Jan 25, 2022
Merged

Add unsafe open mode #79

merged 10 commits into from
Jan 25, 2022

Conversation

q-posev
Copy link
Member

@q-posev q-posev commented Jan 25, 2022

  • 'u' mode is implemented in the trexio_open function. It allows to overwrite single blocks of data and delete entire groups in the TREXIO files;
  • added trexio_delete_[group] functions which can be used in unsafe mode to delete entire groups. Note: this is the only way to modify the existing sparse quantities (e.g. RDMs or ERIs). Sparse data cannot be overwritten but rather has to be deleted first and then written again;
  • unsafe (int) attribute added to metadata group to indicate that the file has been modified in unsafe mode and might be inconsistent. The value is set to 1 upon first unsafe call to trexio_open but can be manually overwritten if the user carefully validated the TREXIO file.

@q-posev q-posev requested a review from scemama January 25, 2022 10:20
src/templates_front/templator_front.org Outdated Show resolved Hide resolved
@scemama scemama merged commit bc92e13 into master Jan 25, 2022
@scemama scemama deleted the add-unsafe-open-mode branch February 23, 2022 15:18
@scemama scemama restored the add-unsafe-open-mode branch February 23, 2022 15:18
@q-posev q-posev deleted the add-unsafe-open-mode branch May 18, 2022 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants