Changes
- Cap the per-query UDP timeout at
min(1.0, timeout)for single-nameserver
configurations as well as multi-nameserver ones. Previously, when only one
nameserver was configured (or the system default list had a single entry),
resolver.timeoutandresolver.lifetimewere both set to the full
timeoutbudget, which collapses dnspython's UDP retry loop to a single
attempt — a single dropped UDP datagram then consumed the whole lifetime
and raisedLifetimeTimeout, whiledig(which defaults to+tries=3)
would mask the same blip by retrying. dnspython now retries UDP within
the lifetime window (~2 attempts at the default 2s budget), matching
dig's behavior in spirit and eliminating spurious single-NS timeouts
on paths with occasional packet loss.