What version are you running?
2.0.11
What's the URL of the page containing the problem?
N/A
What steps will reproduce the problem?
1. Configure RB to use AD auth backend.
2. Configure backend to find servers via DNS
3. Try to login and you a 500 error
What is the expected output? What do you see instead?
I expect to be logging in successfully. Instead I get a 500 error with the following entry in the logs:
[trimmed for brevity]
File "/usr/local/lib/python2.7/dist-packages/ReviewBoard-2.0.11-py2.7.egg/reviewboard/accounts/backends.py", line 552, in find_domain_controllers_from_dns
req = DNS.Base.DnsRequest(q, qtype='SRV').req()
File "/usr/lib/python2.7/dist-packages/DNS/Base.py", line 235, in req
m.addQuestion(qname, qtype, Class.IN)
File "/usr/lib/python2.7/dist-packages/DNS/Lib.py", line 483, in addQuestion
self.add16bit(qtype)
File "/usr/lib/python2.7/dist-packages/DNS/Lib.py", line 81, in add16bit
self.buf = self.buf + pack16bit(n)
File "/usr/lib/python2.7/dist-packages/DNS/Lib.py", line 49, in pack16bit
return struct_pack('!H', n)
error: cannot convert argument to integer
What operating system are you using? What browser?
N/A
Please provide any additional information below.
I dug into the DNS/Lib.py code and the problem is that the RB call to DnsRequest uses a string literal for qtype (which ends up being a unicode string due to the future import at the top of the file). In DNS/Base.py there is code to convert qtype to the native type (DNS.Type) by checking if it is currently one of types.StringTypes; however on one of our configurations types.StringTypes was failing to recognize unicode objects as strings.