From: Artem Y. <se...@sp...> - 2008-12-04 21:10:36
|
On Thu, Dec 4, 2008 at 11:42 PM, Yuri Takhteyev <qar...@gm...> wrote: > > After that you need to make one change manually, in > markdown/inlinepatterns.py: > > -import htmlentitydefs > +from html import entities as htmlentitydefs > > After that, the script seems to work for all test cases except > "para-with-hr". The test-markdown.py itself is broken in 3.0, though, > when it comes to saving the results to a file. As a quick fix, you can > disable this: > > test-markdown.py: > - htmlDiffFile.write(diffsBuffer.decode("utf8")) > + #htmlDiffFile.write(diffsBuffer.decode("utf8")) > > Nice :) What about adding version check ? Something like this: if sys.version >= "3.0": from html import entities as htmlentitydefs else: import htmlentitydefs |