Skip to content
Snippets Groups Projects

[Webservice] Use AW status on myMdC for warnings that prevent launching correction

Merged Thomas Kluyver requested to merge fix/webservice-warn-mymdc into master
All threads resolved!
1 file
+ 4
2
Compare changes
  • Side-by-side
  • Inline
+ 4
2
@@ -770,9 +770,11 @@ async def update_mdc_status(mdc: MetadataClient, action: str,
Further informations are available at:
https://git.xfel.eu/gitlab/detectors/pycalibration/wikis/MyMDC-Communication
"""
if message.split(':')[0] in ('FAILED', 'WARN'): # Errors
if message.startswith('FAILED:'):
flag = 'E'
elif message.split(':')[0] == 'SUCCESS': # Success
elif message.startswith('WARN:'):
flag = 'AW' if action == 'correct' else 'E'
elif message.startswith('SUCCESS:'):
flag = 'IP'
if 'Uploaded' in message or 'Finished' in message:
flag = 'A' if action == 'correct' else 'F'
Loading