[schema] RQL queries are always unicode objects in python 3
fixes commit 42c5bd7286b7.
--- a/schema.py Tue Oct 13 16:12:37 2015 +0200
+++ b/schema.py Wed Oct 14 15:49:03 2015 +0200
@@ -25,7 +25,7 @@
from logging import getLogger
from warnings import warn
-from six import text_type, string_types, add_metaclass
+from six import PY2, text_type, string_types, add_metaclass
from six.moves import range
from logilab.common import tempattr
@@ -146,7 +146,7 @@
added/removed for instance)
"""
union = parse(u'Any 1 WHERE %s' % rqlstring).as_string()
- if isinstance(union, str):
+ if PY2 and isinstance(union, str):
union = union.decode('utf-8')
return union.split(' WHERE ', 1)[1]