Commit 225a3162 authored by Nsukami Patrick's avatar Nsukami Patrick
Browse files

Fix py3 error: No module named cStringIO

parent 98d72e8abc3d
......@@ -7,7 +7,7 @@
__docformat__ = "restructuredtext en"
import os
from cStringIO import StringIO
from io import BytesIO
from logilab.mtconverter import xml_escape
from logilab.common.registry import yes
......@@ -183,7 +183,7 @@ class PDFExportView(EntityView):
os.environ['HOME'] = 'wtf'
os.getcwd = lambda: 'wtf'
# NOTE: we could use self.w.__self__ directly
stream = StringIO()
stream = BytesIO()
writer.write(entity, stream)
self.w(stream.getvalue())
finally:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment