(path)
| 1316 | # Surveillance alerts also respect the permitted-times schedule (if enabled); |
| 1317 | # node-offline + inactivity keep plain notify_on (maintenance / health). |
| 1318 | alerts_now = notify_on and _rusense_within_alert_schedule(now) |
| 1319 | |
| 1320 | # ── Nodes first: the roster feeds BOTH the geofence RSSI windows and the |
| 1321 | # offline detector, so fetch it once and reuse it. ── |
| 1322 | nodes = _rusense_get('/api/v1/nodes') |
| 1323 | node_list = nodes.get('nodes') if isinstance(nodes, dict) else None |
| 1324 | if not isinstance(node_list, list): |
| 1325 | node_list = None |
| 1326 | |
| 1327 | # Extend per-node RSSI windows and evaluate the geofence verdict. A "ghost" |
| 1328 | # is a disturbance with real energy that is NOT corroborated/interior — i.e. |
| 1329 | # a walk-by or through-wall neighbour. When detected we suppress the |
no test coverage detected