Skip to content
Snippets Groups Projects
Commit 808df11f authored by Philipp Schmidt's avatar Philipp Schmidt
Browse files

Change output version to EXDF-v1.3 if file is mislabeled as v1.2

parent 95ccc885
No related branches found
No related tags found
1 merge request!9Properly copy attributes of CONTROL key leafs and RUN-only keys
......@@ -68,6 +68,15 @@ class ReduceWriter(SourceDataWriter):
raise ReduceInitError('Currently input files are required to be '
'EXDF-v1.0+')
elif input_version == Version('1.2') and data.control_sources:
# Check for mislabeled EXDF-v1.3 files.
ctrl_src = next(iter(control_sources))
if data[ctrl_src, ctrl_src.one_key()].attributes():
input_version = Version('1.3')
self.log.warning('Detected EXDF-v1.3 file with attributes '
'mislabeled as EXDF-v1.2')
self.log.debug(f'Input data EXDF version {input_version}')
if version == 'same':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment