diff --git a/AUTHORS.rst b/AUTHORS.rst
index 4148a6ed..e9780455 100644
--- a/AUTHORS.rst
+++ b/AUTHORS.rst
@@ -32,3 +32,4 @@ Patches and suggestions
 - Juan Carlos Garcia Segovia
 - Mike West
 - Marc DM
+- Alexandre Leray
diff --git a/html5lib/treewalkers/lxmletree.py b/html5lib/treewalkers/lxmletree.py
index 375cc2e8..f566dec4 100644
--- a/html5lib/treewalkers/lxmletree.py
+++ b/html5lib/treewalkers/lxmletree.py
@@ -1,5 +1,5 @@
 from __future__ import absolute_import, division, unicode_literals
-from six import text_type
+from six import text_type, string_types, binary_type
 
 from lxml import etree
 from ..treebuilders.etree import tag_regexp
@@ -87,7 +87,7 @@ def __init__(self, fragment_root, obj):
             self.tail = ensure_str(self.obj.tail)
         else:
             self.tail = None
-        self.isstring = isinstance(obj, str) or isinstance(obj, bytes)
+        self.isstring = isinstance(obj, string_types) or isinstance(obj, binary_type)
         # Support for bytes here is Py2
         if self.isstring:
             self.obj = ensure_str(self.obj)