#43516 closed defect (fixed)
dot2tex patch to accomodate pyparsing changes
Reported by: | p-bro | Owned by: | nerdling (Jeremy Lavergne) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.2.1 |
Keywords: | haspatch | Cc: | cooljeanius (Eric Gallager) |
Port: | dot2tex |
Description
dot2tex stopped working for me with the following error:
Traceback (most recent call last): File "/opt/local/bin/dot2tex", line 2, in <module> from dot2tex.dot2tex import main File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/dot2tex/__init__.py", line 36, in <module> import dot2tex as d2t File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/dot2tex/dot2tex.py", line 47, in <module> import dotparsing File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/dot2tex/dotparsing.py", line 26, in <module> from pyparsing import (Literal, CaselessLiteral, Word, Upcase, OneOrMore, ZeroOrMore, ImportError: cannot import name _noncomma
This is due to changes in the pyparsing module. However, _noncomma is not actually used, and so the easy fix is to remove this in the import. The original author has corrected this bug in https://github.com/kjellmf/dot2tex/commit/d189780361b862cdabe4f3499269ad30aa3e1337#diff-abe89aaefb3d77955a9c662a17c1d7d0 (other changes are mostly whitespace). Unfortunately that patch is not yet part of a released version of dot2tex.
I have created a patch that removes the unused _noncomma, and attached the rev-bumped Portfile and the patch. The resulting dot2tex-2.8.7-2 works for me.
Attachments (2)
Change History (8)
Changed 11 years ago by p-bro
Attachment: | patch-dot2tex-dotparsing.py.diff added |
---|
Changed 11 years ago by p-bro
Attachment: | Portfile-dot2tex.diff added |
---|
comment:1 Changed 11 years ago by p-bro
comment:2 Changed 11 years ago by mf2k (Frank Schima)
Owner: | changed from macports-tickets@… to snc@… |
---|
In the future, please Cc the port maintainers (port info --maintainers dot2tex
).
comment:3 Changed 11 years ago by p-bro
Darn, I thought that was done automatically. Sorry about that.
comment:4 Changed 11 years ago by nerdling (Jeremy Lavergne)
Status: | new → assigned |
---|
comment:5 Changed 11 years ago by nerdling (Jeremy Lavergne)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Patched in r119537.
As an aside: The last released dot2tex version is from 2009. The code has since moved to github https://github.com/kjellmf/dot2tex with a number of patches. Apparently a new release is in the making (see https://github.com/kjellmf/dot2tex/commits/master) so it might be worthwhile monitoring github...