def text2html(input_lines): from pep2html import fixfile from StringIO import StringIO s = StringIO() fixfile("", input_lines, s) return s.getvalue().decode("utf-8")
def text2html(input_lines): """ Render a text (non-rst) pep as HTML. This uses all of the original code in pep2html.py convertor in the pep repo. """ from pep2html import fixfile from StringIO import StringIO s = StringIO() fixfile("", input_lines, s) return s.getvalue().decode("utf-8")