From: Waylan L. <wa...@gm...> - 2008-12-05 03:45:05
|
On Thu, Dec 4, 2008 at 5:50 PM, Yuri Takhteyev <qar...@gm...> wrote: >> Nice :) What about adding version check ? Something like this: >> >> if sys.version >= "3.0": >> from html import entities as htmlentitydefs >> else: >> import htmlentitydefs Seeing the code won't run as-is (the user still needs to run 2to3) in 3.0, I do *not* think we should be adding this version check. Obviously, if we are supporting 3.0 (through 2to3) that should be documented and a note about this could be made there. I suppose a comment in the source could help as well. import htmlentitydefs # For Python 3.0+ comment above line and uncomment line below # from html import entities as htmlentitydefs > > We shouldn't _have_ to do that, but works for now. I also realized > that "para-with-hr" already fails, Hmm, it's not failing for me in 2.5. I haven't installed 2.6 yet. My understanding is that that is where we should be testing before running 2to3. I'll have to investigate further. > so the new problem is just limited > to test-markdown.py. (Test-markdown.py fails in python 3.0 when it > tries to save diff for a failed test.) > > So, with the most recent commit (cd73ef7), all you have to do is run > 2to3 on "markdown", "markdown.py" and (optionally) "test-markdown.py". > Cool! -- ---- Waylan Limberg wa...@gm... |