Content-Type: text/plain; charset="utf-8" In-Reply-To: X-Mailer: MIME-tools 5.508 (Entity 5.508) Message-ID: MIME-Version: 1.0 Content-Disposition: inline X-RT-Original-Encoding: utf-8 References: <5139A75F-BE8E-4291-BDC9-711C2F943EFE@ucd.ie> <20171025232729.60E248D09473@rock.dv.isc.org> X-RT-Interface: Web Content-Transfer-Encoding: binary RT-Send-CC: Content-Length: 1115 On Wed Oct 25 13:27:42 2017, marka wrote: > > In message , "Evan > Hunt via RT" writes: > > Mark, what python version were you using? I have 2.7.12 and 3.5.2 > > and > > the test passes for me in both of them. > > [rock:~/git/bind9] marka% python --version > Python 3.5.4 > [rock:~/git/bind9] marka% In python3 open().read() returns a str Popen().communicate() returns a bytearray. In python2 they both return str which is a aliased to bytearray. Anyway I've committed the following. diff --git a/bin/python/isc/checkds.py.in b/bin/python/isc/checkds.py.in index 6adb6dd06c..a1615543a4 100644 --- a/bin/python/isc/checkds.py.in +++ b/bin/python/isc/checkds.py.in @@ -34,7 +34,11 @@ class SECRR: if not rrtext: raise Exception - fields = rrtext.decode('ascii').split() + # 'str' does not have decode method in python3 + if type(rrtext) is not str: + fields = rrtext.decode('ascii').split() + else: + fields = rrtext.split() if len(fields) < 7: raise Exception