NASA-IMPACT / pyQuARC

The pyQuARC tool reads and evaluates metadata records with a focus on the consistency and robustness of the metadata. pyQuARC flags opportunities to improve or add to contextual metadata information in order to help the user connect to relevant data products. pyQuARC also ensures that information common to both the data product and the file-level metadata are consistent and compatible. pyQuARC frees up human evaluators to make more sophisticated assessments such as whether an abstract accurately describes the data and provides the correct contextual information. The base pyQuARC package assesses descriptive metadata used to catalog Earth observation data products and files. As open source software, pyQuARC can be adapted and customized by data providers to allow for quality checks that evolve with their needs, including checking metadata not covered in base package.
Apache License 2.0
20 stars 1 forks source link

Code breaks If Collection/DeleteTime is not in ISO Format #64

Closed andrewdweis closed 3 years ago

andrewdweis commented 3 years ago

Describe the bug In the Collection/DeleteTime field the following occurs:

"File "/Users/aweis/Desktop/ARC/revamped_pycmr-refactor-polish_code/code/datetime_validator.py", line 76, in delete_time_check delete_time.replace( AttributeError: 'bool' object has no attribute 'replace'"

To Reproduce Steps to reproduce the behavior:

  1. Add the Collection/DeleteTime to the test_cmr_metadata.echo10 record
  2. Include any value other than a complete Datetime in ISO format
  3. Run python3 main.py --fake true
  4. See error

Expected behavior If the metadata includes any value other than ISO format it should produce an error message with a FALSE result

slesaad commented 3 years ago

I cannot reproduce this. I tried all three cases and it works as expected. Can you check again @andrewdweis ?