Summary
When a multi-signal operation (n→1 or 2→1) receives signals with incompatible X arrays, surface an interactive prompt asking the user how to proceed (interpolate / abort / always interpolate). Matches DataLab Qt's xarray_compat_behavior setting.
Motivation
Today, X-array mismatch in multi-signal operations either silently interpolates (when skip_xarray_compat=False) or fails with a Python error. Users get no chance to confirm the interpolation, and have no way to make the choice once and remember it. DataLab Qt offers an "ask before interpolating" policy that prompts at the boundary and remembers the answer for the session.
Architectural impact
- Mid-computation modal: Pyodide runs synchronously from the host's perspective, but the prompt must be raised mid-dispatch and resolved before the operation continues. This requires either:
- splitting the dispatch into a "validate + prompt + execute" pipeline owned by TS, or
- exposing a Python ↔ TS callback (similar to how progress callbacks could work) so Python can
await a user decision.
- Session memory: the "always interpolate / always abort" choice must be scoped (per-session? until Preferences change? per-operation type?) and stored somewhere the dispatcher can read it without a round trip.
- Action surface: the dispatcher already accepts
skip_xarray_compat=True for operations that intentionally use mismatched X arrays — the new flow must respect that bypass.
- Error reporting: when the user picks "abort", the failure must surface in the existing notification system without dumping a Python traceback.
Acceptance criteria
References
- DataLab desktop: X-axis compatibility logic in
datalab/gui/processor/base.py (lines ~1764, 1886) and the xarray_compat_behavior setting
- Web today:
skip_xarray_compat flag on register_2_to_1 / register_n_to_1 in src/runtime/processor.py
Summary
When a multi-signal operation (n→1 or 2→1) receives signals with incompatible X arrays, surface an interactive prompt asking the user how to proceed (interpolate / abort / always interpolate). Matches DataLab Qt's
xarray_compat_behaviorsetting.Motivation
Today, X-array mismatch in multi-signal operations either silently interpolates (when
skip_xarray_compat=False) or fails with a Python error. Users get no chance to confirm the interpolation, and have no way to make the choice once and remember it. DataLab Qt offers an "ask before interpolating" policy that prompts at the boundary and remembers the answer for the session.Architectural impact
awaita user decision.skip_xarray_compat=Truefor operations that intentionally use mismatched X arrays — the new flow must respect that bypass.Acceptance criteria
tests/python/cover the detection logic and the bypass viaskip_xarray_compat=True.References
datalab/gui/processor/base.py(lines ~1764, 1886) and thexarray_compat_behaviorsettingskip_xarray_compatflag onregister_2_to_1/register_n_to_1insrc/runtime/processor.py