Skip to content
Snippets Groups Projects

Pop internal disable-correct key from data mapping

Merged Philipp Schmidt requested to merge fix/disable-correct-passing into master
All threads resolved!
1 file
+ 7
1
Compare changes
  • Side-by-side
  • Inline
+ 7
1
@@ -910,7 +910,7 @@ class ActionsServer:
for karabo_id in pconf:
dconfig = data_conf[karabo_id]
if dconfig.get('disable-correct', False):
if dconfig.pop('disable-correct', False):
# Skip this detector installation for
# corrections if disabled.
continue
@@ -1036,6 +1036,9 @@ class ActionsServer:
triple = any(det in karabo_id for det in
["LPD", "AGIPD", "JUNGFRAU", "JF", "JNGFR"])
# This fails silently if the hardcoded strings above are
# ever changed (triple = False) but the underlying notebook
# still expects run-high/run-med/run-low.
if triple and len(runs) == 1:
runs_dict = {'run-high': runs[0],
'run-med': '0',
@@ -1051,6 +1054,9 @@ class ActionsServer:
# is not migrated, thus skipping some validation here.
thisconf = copy.copy(data_conf[karabo_id])
# Pop internal key to avoid propagation to xfel-calibrate.
thisconf.pop('disable-correct', None)
if (karabo_id in pconf
and isinstance(pconf[karabo_id], dict)):
thisconf.update(copy.copy(pconf[karabo_id]))
Loading