server/sources/native.py
changeset 10612 84468b90e9c1
parent 10609 e2d8e81bfe68
child 10651 9ca33768473c
--- a/server/sources/native.py	Wed Sep 16 11:23:51 2015 +0200
+++ b/server/sources/native.py	Mon Sep 14 16:03:07 2015 +0200
@@ -38,6 +38,7 @@
 import logging
 import sys
 
+from six import string_types
 from six.moves import range, cPickle as pickle
 
 from logilab.common.decorators import cached, clear_cache
@@ -558,7 +559,7 @@
                 sql, qargs, cbs = self._rql_sqlgen.generate(union, args, varmap)
                 self._cache[cachekey] = sql, qargs, cbs
         args = self.merge_args(args, qargs)
-        assert isinstance(sql, basestring), repr(sql)
+        assert isinstance(sql, string_types), repr(sql)
         cursor = self.doexec(cnx, sql, args)
         results = self.process_result(cursor, cnx, cbs)
         assert dbg_results(results)