DMSC Integration Testing

Last updated: May 27, 2026 07:24:18

Test: nexusfiles-scipp|loki|can_compute_wavelength|beam_monitor_m4

View job log here


workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_loki_999999_00004623.hdf')
detector_name = 'beam_monitor_m4'

@pytest.mark.parametrize(
"detector_name",
[f"loki_detector_{i}" for i in range(9)] + [f"beam_monitor_m{i}" for i in range(5)],
)
def test_can_compute_wavelength(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, detector_name: str
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path

if "monitor" in detector_name:
workflow[NeXusMonitorName[Incident]] = detector_name
> result = workflow.compute(WavelengthMonitor[SampleRun, Incident])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/loki/loki_reduction_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
return self.get(tp, **kwargs).compute(reporter=reporter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
return self._dask_get(dsk, list(map(_to_dask_key, keys)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/threaded.py:91: in get
results = get_async(
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:549: in get_async
raise_exception(exc, tb)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:353: in reraise
raise exc
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:258: in execute_task
result = task(data)
^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/_task_spec.py:759: in __call__
return self.func(*new_argspec)
^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/utils.py:80: in apply
return func(*args)
^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:360: in to_transformation
t.value = _apply_time_filter(t.value['time', interval.value], time_filter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:309: in _apply_time_filter
return user_filter(transform)
^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

transform =
Dimensions: Sizes[time:0, ]
Coordinates:
* average_value float64 [m] () 0... datetime64 [ns] (time) []
Data:
float64 [m] (time) []



def reject_time_dependent_transform(
transform: sc.DataArray,
) -> Never:
"""Raise a value error to forbid time-dependent transformations by default."""
> raise ValueError(
f"Transform is time-dependent: {transform}, but no filter is provided."
)
E ValueError: Transform is time-dependent:
E Dimensions: Sizes[time:0, ]
E Coordinates:
E * average_value float64 [m] () 0
E * maximum_value float64 [m] () 0
E * minimum_value float64 [m] () 0
E * time datetime64 [ns] (time) []
E Data:
E float64 [m] (time) []
E
E , but no filter is provided.

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:298: ValueError

View job log here


workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_loki_999999_00004469.hdf')
detector_name = 'beam_monitor_m4'

@pytest.mark.parametrize(
"detector_name",
[f"loki_detector_{i}" for i in range(9)] + [f"beam_monitor_m{i}" for i in range(5)],
)
def test_can_compute_wavelength(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, detector_name: str
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path

if "monitor" in detector_name:
workflow[NeXusMonitorName[Incident]] = detector_name
> result = workflow.compute(WavelengthMonitor[SampleRun, Incident])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/loki/loki_reduction_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
return self.get(tp, **kwargs).compute(reporter=reporter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
return self._dask_get(dsk, list(map(_to_dask_key, keys)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/threaded.py:91: in get
results = get_async(
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:549: in get_async
raise_exception(exc, tb)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:353: in reraise
raise exc
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:258: in execute_task
result = task(data)
^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/_task_spec.py:759: in __call__
return self.func(*new_argspec)
^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/utils.py:80: in apply
return func(*args)
^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:360: in to_transformation
t.value = _apply_time_filter(t.value['time', interval.value], time_filter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:309: in _apply_time_filter
return user_filter(transform)
^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

transform =
Dimensions: Sizes[time:0, ]
Coordinates:
* average_value float64 [m] () 0... datetime64 [ns] (time) []
Data:
float64 [m] (time) []



def reject_time_dependent_transform(
transform: sc.DataArray,
) -> Never:
"""Raise a value error to forbid time-dependent transformations by default."""
> raise ValueError(
f"Transform is time-dependent: {transform}, but no filter is provided."
)
E ValueError: Transform is time-dependent:
E Dimensions: Sizes[time:0, ]
E Coordinates:
E * average_value float64 [m] () 0
E * maximum_value float64 [m] () 0
E * minimum_value float64 [m] () 0
E * time datetime64 [ns] (time) []
E Data:
E float64 [m] (time) []
E
E , but no filter is provided.

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:298: ValueError

View job log here


workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_loki_999999_00003362.hdf')
detector_name = 'beam_monitor_m4'

@pytest.mark.parametrize(
"detector_name",
[f"loki_detector_{i}" for i in range(9)] + [f"beam_monitor_m{i}" for i in range(5)],
)
def test_can_compute_wavelength(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, detector_name: str
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path

if "monitor" in detector_name:
workflow[NeXusMonitorName[Incident]] = detector_name
> result = workflow.compute(WavelengthMonitor[SampleRun, Incident])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/loki/loki_reduction_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
return self.get(tp, **kwargs).compute(reporter=reporter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
return self._dask_get(dsk, list(map(_to_dask_key, keys)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/threaded.py:91: in get
results = get_async(
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:549: in get_async
raise_exception(exc, tb)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:353: in reraise
raise exc
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:258: in execute_task
result = task(data)
^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/_task_spec.py:759: in __call__
return self.func(*new_argspec)
^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/utils.py:80: in apply
return func(*args)
^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:360: in to_transformation
t.value = _apply_time_filter(t.value['time', interval.value], time_filter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:309: in _apply_time_filter
return user_filter(transform)
^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

transform =
Dimensions: Sizes[time:0, ]
Coordinates:
* average_value float64 [m] () 0... datetime64 [ns] (time) []
Data:
float64 [m] (time) []



def reject_time_dependent_transform(
transform: sc.DataArray,
) -> Never:
"""Raise a value error to forbid time-dependent transformations by default."""
> raise ValueError(
f"Transform is time-dependent: {transform}, but no filter is provided."
)
E ValueError: Transform is time-dependent:
E Dimensions: Sizes[time:0, ]
E Coordinates:
E * average_value float64 [m] () 0
E * maximum_value float64 [m] () 0
E * minimum_value float64 [m] () 0
E * time datetime64 [ns] (time) []
E Data:
E float64 [m] (time) []
E
E , but no filter is provided.

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:298: ValueError

View job log here


workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_loki_999999_00003227.hdf')
detector_name = 'beam_monitor_m4'

@pytest.mark.parametrize(
"detector_name",
[f"loki_detector_{i}" for i in range(9)] + [f"beam_monitor_m{i}" for i in range(5)],
)
def test_can_compute_wavelength(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, detector_name: str
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path

if "monitor" in detector_name:
workflow[NeXusMonitorName[Incident]] = detector_name
> result = workflow.compute(WavelengthMonitor[SampleRun, Incident])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/loki/loki_reduction_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
return self.get(tp, **kwargs).compute(reporter=reporter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
return self._dask_get(dsk, list(map(_to_dask_key, keys)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/threaded.py:91: in get
results = get_async(
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:549: in get_async
raise_exception(exc, tb)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:353: in reraise
raise exc
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:258: in execute_task
result = task(data)
^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/_task_spec.py:759: in __call__
return self.func(*new_argspec)
^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/utils.py:80: in apply
return func(*args)
^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:360: in to_transformation
t.value = _apply_time_filter(t.value['time', interval.value], time_filter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:309: in _apply_time_filter
return user_filter(transform)
^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

transform =
Dimensions: Sizes[time:0, ]
Coordinates:
* average_value float64 [m] () 0... datetime64 [ns] (time) []
Data:
float64 [m] (time) []



def reject_time_dependent_transform(
transform: sc.DataArray,
) -> Never:
"""Raise a value error to forbid time-dependent transformations by default."""
> raise ValueError(
f"Transform is time-dependent: {transform}, but no filter is provided."
)
E ValueError: Transform is time-dependent:
E Dimensions: Sizes[time:0, ]
E Coordinates:
E * average_value float64 [m] () 0
E * maximum_value float64 [m] () 0
E * minimum_value float64 [m] () 0
E * time datetime64 [ns] (time) []
E Data:
E float64 [m] (time) []
E
E , but no filter is provided.

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:298: ValueError

View job log here


workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_loki_999999_00003083.hdf')
detector_name = 'beam_monitor_m4'

@pytest.mark.parametrize(
"detector_name",
[f"loki_detector_{i}" for i in range(9)] + [f"beam_monitor_m{i}" for i in range(5)],
)
def test_can_compute_wavelength(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, detector_name: str
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path

if "monitor" in detector_name:
workflow[NeXusMonitorName[Incident]] = detector_name
> result = workflow.compute(WavelengthMonitor[SampleRun, Incident])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/loki/loki_reduction_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
return self.get(tp, **kwargs).compute(reporter=reporter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
return self._dask_get(dsk, list(map(_to_dask_key, keys)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/threaded.py:91: in get
results = get_async(
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:549: in get_async
raise_exception(exc, tb)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:353: in reraise
raise exc
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:258: in execute_task
result = task(data)
^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/_task_spec.py:759: in __call__
return self.func(*new_argspec)
^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/utils.py:80: in apply
return func(*args)
^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:360: in to_transformation
t.value = _apply_time_filter(t.value['time', interval.value], time_filter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:309: in _apply_time_filter
return user_filter(transform)
^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

transform =
Dimensions: Sizes[time:0, ]
Coordinates:
* average_value float64 [m] () 0... datetime64 [ns] (time) []
Data:
float64 [m] (time) []



def reject_time_dependent_transform(
transform: sc.DataArray,
) -> Never:
"""Raise a value error to forbid time-dependent transformations by default."""
> raise ValueError(
f"Transform is time-dependent: {transform}, but no filter is provided."
)
E ValueError: Transform is time-dependent:
E Dimensions: Sizes[time:0, ]
E Coordinates:
E * average_value float64 [m] () 0
E * maximum_value float64 [m] () 0
E * minimum_value float64 [m] () 0
E * time datetime64 [ns] (time) []
E Data:
E float64 [m] (time) []
E
E , but no filter is provided.

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:298: ValueError

View job log here


parent =
depends_on = DependsOn(parent='/entry/instrument/beam_monitor_m4/transformations', value='/entry/instrument/beamstop_z1')

def parse_depends_on_chain(
parent: Field | Group, depends_on: DependsOn
) -> TransformationChain | None:
"""Follow a depends_on chain and return the transformations."""
chain = TransformationChain(depends_on.parent, depends_on.value)
# Use raw h5py objects to follow the chain because that avoids constructing
# expensive intermediate snx.Group objects.
file = parent.underlying.file
visited = [depends_on.absolute_path()]
try:
while not depends_on.is_terminal:
transform, base = _locate_depends_on_target(
file, depends_on, parent.definitions
)
> depends_on = DependsOn(parent=base, value=transform.attrs['depends_on'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/scippnexus/nxtransformations.py:322:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = , name = 'depends_on'

def __getitem__(self, name: str) -> Any:
> attr = self._attrs[name]
^^^^^^^^^^^^^^^^^
E KeyError: 'depends_on'

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/scippnexus/attrs.py:18: KeyError

During handling of the above exception, another exception occurred:

workflow =
coda_nexus_file_path = PosixPath('/ess/data/coda/999999/raw/coda_loki_999999_00002533.hdf')
detector_name = 'beam_monitor_m4'

@pytest.mark.parametrize(
"detector_name",
[f"loki_detector_{i}" for i in range(9)] + [f"beam_monitor_m{i}" for i in range(5)],
)
def test_can_compute_wavelength(
workflow: sciline.Pipeline, coda_nexus_file_path: Path, detector_name: str
) -> None:
workflow[Filename[SampleRun]] = coda_nexus_file_path

if "monitor" in detector_name:
workflow[NeXusMonitorName[Incident]] = detector_name
> result = workflow.compute(WavelengthMonitor[SampleRun, Incident])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

tests/nexusfiles-scipp/loki/loki_reduction_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/pipeline.py:191: in compute
return self.get(tp, **kwargs).compute(reporter=reporter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/task_graph.py:122: in compute
return self._scheduler.get(self._graph, [targets], reporter=reporter)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/sciline/scheduler.py:119: in get
return self._dask_get(dsk, list(map(_to_dask_key, keys)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/threaded.py:91: in get
results = get_async(
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:549: in get_async
raise_exception(exc, tb)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:353: in reraise
raise exc
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/local.py:258: in execute_task
result = task(data)
^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/_task_spec.py:759: in __call__
return self.func(*new_argspec)
^^^^^^^^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/dask/utils.py:80: in apply
return func(*args)
^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/workflow.py:233: in load_nexus_component
nexus.load_component(location, nx_class=nx_class, definitions=definitions)
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/ess/reduce/nexus/_nexus_loader.py:105: in load_component
loaded = cast(sc.DataGroup, group[selection])
^^^^^^^^^^^^^^^^
.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/scippnexus/base.py:399: in __getitem__
if (chain := parse_depends_on_chain(self, dg['depends_on'])) is not None:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

parent =
depends_on = DependsOn(parent='/entry/instrument/beam_monitor_m4/transformations', value='/entry/instrument/beamstop_z1')

def parse_depends_on_chain(
parent: Field | Group, depends_on: DependsOn
) -> TransformationChain | None:
"""Follow a depends_on chain and return the transformations."""
chain = TransformationChain(depends_on.parent, depends_on.value)
# Use raw h5py objects to follow the chain because that avoids constructing
# expensive intermediate snx.Group objects.
file = parent.underlying.file
visited = [depends_on.absolute_path()]
try:
while not depends_on.is_terminal:
transform, base = _locate_depends_on_target(
file, depends_on, parent.definitions
)
depends_on = DependsOn(parent=base, value=transform.attrs['depends_on'])
chain.transformations[transform.name] = transform[()]
if depends_on.absolute_path() in visited:
raise ValueError(
'Circular depends_on chain detected: '
f'{[*visited, depends_on.absolute_path()]}'
)
visited.append(depends_on.absolute_path())
except KeyError as e:
> warnings.warn(
UserWarning(
f'depends_on chain {depends_on} references missing node {e}'.replace(
'\n', ''
)
),
stacklevel=2,
)
E UserWarning: depends_on chain DependsOn(parent='/entry/instrument/beam_monitor_m4/transformations', value='/entry/instrument/beamstop_z1') references missing node 'depends_on'

.tox/nexusfiles-scipp-loki/lib/python3.12/site-packages/scippnexus/nxtransformations.py:331: UserWarning