fix(rt): default scan_timeout 300 s (top-up refills hold RT scans on purpose)

The 5 s data_timeout warning is unchanged. A 60 s failure would abort scans
that the RT controller holds on purpose during top-up refills.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M8zoDygkWk6LupmHh3tyET
This commit is contained in:
Mirko HollerandClaude Opus 5.5 authored and holler committed 2026-11-22 16:35:00 +01:00
1 parent 9ac866eb65
commit 11e291b80b
5 files changed
+16 -12

No files matched your search

+3 -2
View File
@@ -814,7 +814,8 @@ class RtFlomniFlyer(Device):
socket_cls=SocketIO,
device_manager=None,
data_timeout: float | None = 5.0,
scan_timeout: float | None = 60.0,
# 300 s: top-up refills hold the RT scan on purpose (Mirko 2026-11-22)
scan_timeout: float | None = 300.0,
**kwargs,
):
super().__init__(prefix=prefix, name=name, parent=parent, **kwargs)
@@ -848,7 +849,7 @@ class RtFlomniFlyer(Device):
@property
def scan_timeout(self) -> float | None:
"""Seconds without progress before failing the scan (default: 60).
"""Seconds without progress before failing the scan (default: 300).
Progress means an advancing controller position until the first sample,
then receipt of new samples. Set to None to disable timeout failures.
+3 -2
View File
@@ -758,7 +758,8 @@ class RtLamniFlyer(Device):
socket_cls=SocketIO,
device_manager=None,
data_timeout: float | None = 5.0,
scan_timeout: float | None = 60.0,
# 300 s: top-up refills hold the RT scan on purpose (Mirko 2026-11-22)
scan_timeout: float | None = 300.0,
**kwargs,
):
super().__init__(prefix=prefix, name=name, parent=parent, **kwargs)
@@ -793,7 +794,7 @@ class RtLamniFlyer(Device):
@property
def scan_timeout(self) -> float | None:
"""Seconds without progress before failing the scan (default: 60).
"""Seconds without progress before failing the scan (default: 300).
Progress means an advancing controller position until the first sample,
then receipt of new samples. Set to None to disable timeout failures.
+3 -2
View File
@@ -1208,7 +1208,8 @@ class RtOMNYFlyer(Device):
socket_cls=SocketIO,
device_manager=None,
data_timeout: float | None = 5.0,
scan_timeout: float | None = 60.0,
# 300 s: top-up refills hold the RT scan on purpose (Mirko 2026-11-22)
scan_timeout: float | None = 300.0,
**kwargs,
):
super().__init__(prefix=prefix, name=name, parent=parent, **kwargs)
@@ -1237,7 +1238,7 @@ class RtOMNYFlyer(Device):
@property
def scan_timeout(self) -> float | None:
"""Seconds without progress before failing the scan (default: 60).
"""Seconds without progress before failing the scan (default: 300).
Progress means an advancing controller position until the first sample,
then receipt of new samples. Set to None to disable timeout failures.
+3 -2
View File
@@ -62,7 +62,7 @@ class RtDataMonitor:
"""
def __init__(
self, data_timeout: float | None = 5.0, scan_timeout: float | None = 60.0
self, data_timeout: float | None = 5.0, scan_timeout: float | None = 300.0
) -> None:
"""Configure the warning and failure thresholds for stalled progress.
@@ -70,7 +70,8 @@ class RtDataMonitor:
data_timeout (float | None): Seconds without progress before logging one
warning per stall. Defaults to 5 seconds. Pass None to disable warnings.
scan_timeout (float | None): Seconds without progress before failing the
flyer completion status. Defaults to 60 seconds. Pass None to disable
flyer completion status. Defaults to 300 seconds (top-up refills hold
the RT scan on purpose). Pass None to disable
timeout failures.
Raises:
+4 -4
View File
@@ -169,10 +169,10 @@ def test_received_points_reset_scan_timeout(flyer, clock):
assert flyer.data.set.call_count == 5
def test_default_scan_timeout_is_sixty_seconds(flyer, clock):
assert flyer.scan_timeout == 60
status = run_readout(flyer, clock, [(0, 2, 0), (59.999, 2, 0), (60, 2, 0)], failure=True)
assert "scan_timeout=60 s" in str(status.exception())
def test_default_scan_timeout_is_five_minutes(flyer, clock):
assert flyer.scan_timeout == 300
status = run_readout(flyer, clock, [(0, 2, 0), (299.999, 2, 0), (300, 2, 0)], failure=True)
assert "scan_timeout=300 s" in str(status.exception())
@pytest.mark.parametrize("name", ["data_timeout", "scan_timeout"])