You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
async_update_interfaces does not report whether the requested interfaces were bound #1916
Zeroconf.async_update_interfaces is best-effort and returns None, so a caller cannot tell whether the requested configuration was applied.
Two failure paths are logged and swallowed:
A listen socket rebuild that fails, for example switching an IPv4 instance to IPVersion.All on a host that cannot open a dual-stack AF_INET6 socket. The engine logs Skipping interface update; listen socket rebuild failed and returns False.
A requested interface that fails to bind. The engine logs Interface ... not added once and carries on.
In both cases Zeroconf.async_update_interfaces still commits the requested interfaces and ip_version as the retained configuration, and returns normally.
A caller that asks for dual-stack and cannot get it has no signal to fall back to IPVersion.V4Only, or to retry later. It also cannot log an accurate outcome: a caller that logs "reconciled with IPVersion.All" after a swallowed rebuild failure is wrong.
In esphome/device-builder#2864 this meant a runtime IPv4-only fallback could not be implemented, because the failure it would react to never surfaces.
Suggested fix
Report the outcome from the public method. Options:
Return whether the desired interface set fully bound, or the list of interfaces that were skipped.
Raise when the address family rebuild fails, since in that case none of the requested change was applied.
Either keeps the best-effort behaviour for per-interface failures while letting callers react.
Activity