fix: get_dhcp_leases raises when no lease source answered (#27) #29

Merged
christianmanivong merged 1 commits from fix/dhcp-leases-raise-when-unread into master 2026-10-20 23:36:59 +00:00
1 Commits
Author SHA1 Message Date
Christian Manivong 5a6e573300 fix: get_dhcp_leases raises when no lease source answered (#27)
CI / test (3.10) (push) Successful in 32s
CI / test (3.11) (push) Successful in 34s
CI / test (3.12) (push) Successful in 33s
CI / test (3.10) (pull_request) Successful in 32s
CI / test (3.11) (pull_request) Successful in 29s
CI / test (3.12) (pull_request) Successful in 34s
When Kea, ISC DHCP and the ARP fallback all failed, get_dhcp_leases()
returned [], which a caller cannot tell from a server with no leases. It now
raises a RuntimeError naming each failure, and returns [] only when a source
answered with nothing. An empty ARP table after both lease sources failed
counts as unread too, since ARP rows are no lease data.

Closes #27
2026-10-21 01:01:52 +02:00