From 2271db001eb818d673b0ff8ea16866b95261e3ec Mon Sep 17 00:00:00 2001 From: Bob Halley Date: Fri, 29 May 2020 08:48:23 -0700 Subject: [PATCH] the prior fix for exception handling was still not right, missing a continue --- dns/resolver.py | 1 + dns/trio/resolver.py | 1 + 2 files changed, 2 insertions(+) diff --git a/dns/resolver.py b/dns/resolver.py index f9dbd641..54ed5292 100644 --- a/dns/resolver.py +++ b/dns/resolver.py @@ -1094,6 +1094,7 @@ class Resolver(object): continue except Exception as ex: (_, done) = resolution.query_result(None, ex) + continue (answer, done) = resolution.query_result(response, None) # Note we need to say "if answer is not None" and not just # "if answer" because answer implements __len__, and python diff --git a/dns/trio/resolver.py b/dns/trio/resolver.py index 4551857c..07e70f97 100644 --- a/dns/trio/resolver.py +++ b/dns/trio/resolver.py @@ -127,6 +127,7 @@ class Resolver(dns.resolver.Resolver): raise NotImplementedError except Exception as ex: (_, done) = resolution.query_result(None, ex) + continue (answer, done) = resolution.query_result(response, None) # Note we need to say "if answer is not None" and not just # "if answer" because answer implements __len__, and python -- 2.47.3