Bug in resolver.py?

130 views
Skip to first unread message

Rama

unread,
Jul 16, 2013, 10:57:27 PM7/16/13
to dnspyth...@googlegroups.com
Hello there!

I was trying some IPv6 forward DNS queries when for a particular host name (eqix-dc5.ctbs.com), I received the following error:

answers = dns.resolver.query(host_name, 'AAAA')
  File "/usr/local/lib/python2.7/dist-packages/dns/resolver.py", line 975, in query
    raise_on_no_answer, source_port)
  File "/usr/local/lib/python2.7/dist-packages/dns/resolver.py", line 882, in query
    if rcode != dns.rcode.SERVFAIL or not retry_servfail:
NameError: global name 'retry_servfail' is not defined

I looked into resolver.py, and I changed retry_servfail to self.retry_servfail and things seem to work. Do let me know if my fix is Ok!

Thanks,
Rama

tidou...@gmail.com

unread,
Jul 27, 2013, 11:03:38 AM7/27/13
to dnspyth...@googlegroups.com
I just ran into the same bug and arrived at the same fix.  So I at least think your fix is OK.  :)
Reply all
Reply to author
Forward
0 new messages