🚧 WIP
This commit is contained in:
@@ -276,9 +276,11 @@ def _validate(config: Config) -> None:
|
||||
)
|
||||
if config.opc.connect_timeout_s <= 0:
|
||||
raise ConfigError(f"opc.connect_timeout_s: must be > 0, got {config.opc.connect_timeout_s}")
|
||||
if not config.tags:
|
||||
if not config.tags and not config.devices:
|
||||
raise ConfigError(
|
||||
"tags: at least one tag is required — without tags there is nothing to monitor"
|
||||
"tags: nothing to monitor - define at least one tag or device "
|
||||
"indicator (devices: entries alone are fine, tags: entries alone "
|
||||
"are fine; both empty means the tool would read nothing)"
|
||||
)
|
||||
names = [t.name for t in config.tags]
|
||||
duplicates = sorted({n for n in names if names.count(n) > 1})
|
||||
|
||||
Reference in New Issue
Block a user