(event_type, data)
| 9166 | always equalled the total, Offline was always 0, and New/Lost only ever |
| 9167 | held the difference between two consecutive 15 second syncs. |
| 9168 | |
| 9169 | active / inactive: the live presence verdict where there is one, the |
| 9170 | stored status otherwise (Ragnar's own address, another saved network, |
| 9171 | the first seconds after start). |
| 9172 | new: hosts first seen within TARGET_RECENT_HOURS. |
| 9173 | lost: hosts that were answering and went Offline within |
| 9174 | TARGET_RECENT_HOURS, and are still Offline. |
| 9175 | """ |
| 9176 | presence = presence or {} |
| 9177 | now = now or datetime.now() |
| 9178 | wall_now = time.time() |
| 9179 | recent = timedelta(hours=TARGET_RECENT_HOURS) |
no test coverage detected