AllenNeuralDynamics / AllenNeuralDynamics/aind-metadata-manager

Quality control write_standard_file() will overwrite existing metadata

Open
#33 0 comments 0 reactions 1 assignee Claimed by @seanmcculloch View on GitHub
Dominant language
Python
Stars
0
Forks
0
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
At [this line](https://github.com/AllenNeuralDynamics/aind-metadata-manager/blob/11e9f2fa2b0be6bb84cceda6976dcc5b3e19f880/src/aind_metadata_manager/metadata_manager.py#L550) the existing manager code calls `write_standard_file()` for the QC metadata. If a previous quality_control.json file existed, it will be overwritten at this step.

**Expected behavior**
If one exists, a previous quality_control.json file should be loaded, validated as a `QualityControl` object and then merged with the new QC metrics by calling `qc = qc_old + qc_new`. Then `qc.write_standard_file()` on the final merged output.

**Other context**
This was also happening for processing metadata, but I flagged this to Sean in a separate PR and it sounds like he'll fix it there.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.