Skip to content
Snippets Groups Projects
Commit 86a77e80 authored by David McKenna's avatar David McKenna
Browse files

Merge branch 'continue_on_no_data_metadata' into 'main'

FIX: Only error if data is present and metadata is missing

See merge request !37
parents b7a77e29 c1a88c7c
No related branches found
No related tags found
1 merge request!37FIX: Only error if data is present and metadata is missing
Pipeline #120915 passed
Pipeline: l2json

#120916

    ...@@ -176,9 +176,13 @@ def fetch_from_minio( ...@@ -176,9 +176,13 @@ def fetch_from_minio(
    tqdm_desc="Parsing metadata", tqdm_desc="Parsing metadata",
    ) )
    ] ]
    if not len(metadata):
    raise KeyError(f"No metadata was found for {station}/{statistics_type}/{antennafield} @ {tstart} - {tend}")
    else: else:
    metadata = [] metadata = []
    if fetch_metadata and not len(metadata):
    if len(data):
    raise KeyError(f"No metadata was found for {station}/{statistics_type}/{antennafield} @ {tstart} - {tend}")
    else:
    print(f"No metadata was found for {station}/{statistics_type}/{antennafield} @ {tstart} - {tend}")
    return metadata, data return metadata, data
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Please register or to comment