feat(scada): require complete authorized investigation evidence
Generic Container CI/CD / test-build-publish (push) Successful in 5m52s
Server CI/CD v2 / build-test-publish-and-deploy (push) Successful in 5m52s

This commit is contained in:
2026-11-07 21:15:01 +08:00
parent 2552a9b40d
commit 06d8539aa8
12 changed files with 498 additions and 30 deletions
+14 -2
View File
@@ -106,8 +106,20 @@ class WindowInput(PageInput):
class ScadaInput(WindowInput):
device_ids: list[Id] = Field(min_length=1, max_length=20)
field: Literal["monitored_value", "cleaned_value"] = "monitored_value"
device_ids: list[Id] | None = Field(
default=None, min_length=1, max_length=20,
description="Omit to read the complete SCADA catalogue and all authorized readings in the window; explicit IDs select a paginated detail query.",
)
field: Literal["monitored_value", "cleaned_value"] = Field(
default="monitored_value",
description="Field for explicit-device detail queries; complete all-device reads return both raw and cleaned values.",
)
@model_validator(mode="after")
def complete_query_starts_at_zero(self):
if self.device_ids is None and self.offset:
raise ValueError("All-device SCADA queries read every page internally; offset must be zero")
return self
class BaselineSeriesInput(WindowInput):