Commit e23e32f3 authored by Valentin Valls's avatar Valentin Valls
Browse files

Update the scan_info during the prepared event

parent f4f5960b
...@@ -42,7 +42,7 @@ class ScanNode(DataNodeContainer): ...@@ -42,7 +42,7 @@ class ScanNode(DataNodeContainer):
def dataset(self): def dataset(self):
return self.parent return self.parent
def prepared(self): def prepared(self, scan_info):
"""Publish PREPARED event in Redis """Publish PREPARED event in Redis
""" """
if not self.new_node: if not self.new_node:
...@@ -51,6 +51,7 @@ class ScanNode(DataNodeContainer): ...@@ -51,6 +51,7 @@ class ScanNode(DataNodeContainer):
# TODO: what does the comment above mean? # TODO: what does the comment above mean?
with settings.pipeline(self._prepared_stream, self._info): with settings.pipeline(self._prepared_stream, self._info):
event = PreparedScanEvent() event = PreparedScanEvent()
self._info.update(scan_info)
self._prepared_stream.add_event(event) self._prepared_stream.add_event(event)
def end(self, exception=None): def end(self, exception=None):
......
...@@ -1280,7 +1280,8 @@ class Scan: ...@@ -1280,7 +1280,8 @@ class Scan:
self._fill_meta("fill_meta_at_scan_start") self._fill_meta("fill_meta_at_scan_start")
self.node.prepared() # The scan info was updated with device metadata
self.node.prepared(self._scan_info)
self._axes_in_scan = self._get_data_axes(include_calc_reals=True) self._axes_in_scan = self._get_data_axes(include_calc_reals=True)
with execute_pre_scan_hooks(self._axes_in_scan): with execute_pre_scan_hooks(self._axes_in_scan):
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment