Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 490426 - media-gfx/pydot and dev-tex/dot2tex not compatible with dev-python/pyparsing-2.0.1
Summary: media-gfx/pydot and dev-tex/dot2tex not compatible with dev-python/pyparsing-...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-04 20:12 UTC by Steven Trogdon
Modified: 2014-11-09 15:43 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Set the correct pyparsing dependency for dot2tex, and update the homepage (00001_patch_dot2tex-pyparsing.patch,667 bytes, patch)
2014-02-16 14:44 UTC, karlson.kel
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Steven Trogdon 2013-11-04 20:12:49 UTC
Here I have media-gfx/pydot-1.0.28-r1, dev-tex/dot2tex-2.8.7 and the subject dev-python/pyparsing installed. media-gfx/pydot provides dot_parser.py and dev-tex/dot2tex provides dotparsing.py. From python I get:

>>> import dot_parser
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python2.7/site-packages/dot_parser.py", line 25, in <module>
    from pyparsing import ( nestedExpr, Literal, CaselessLiteral, Word, Upcase, OneOrMore, ZeroOrMore,
ImportError: cannot import name _noncomma
>>>

and

>>> from dot2tex import dotparsing
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python2.7/site-packages/dot2tex/__init__.py", line 36, in <module>
    import dot2tex as d2t
  File "/usr/lib64/python2.7/site-packages/dot2tex/dot2tex.py", line 47, in <module>
    import dotparsing
  File "/usr/lib64/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
>>>

The failing line from both dot_parser.py and dotparsing.py includes

from pyparsing import ( ..., _noncomma, ... )

_noncomma which is defined as

_noncomma = "".join( [ c for c in printables if c != "," ] )

does appear to be present in <dev-python/pyparsing-2.0.1
Comment 1 José María Fernández González 2013-11-28 21:16:25 UTC
I can confirm that dev-tex/dot2tex-2.8.7-r1 also breaks with dev-python/pyparsing-2.0.1.

And, if I downgrade to dev-python/pyparsing-1.5.6-r2 (or lower), dev-tex/dot2tex-2.8.7-r1 works again.
Comment 2 karlson.kel 2014-02-16 14:44:47 UTC
Created attachment 370546 [details, diff]
Set the correct pyparsing dependency for dot2tex, and update the homepage

I can confirm the issue and fixed it by masking versions >pyparsing-2 in the Dependencies.

Since fauskes.net closed in 2010 [1], i guess the projects homepage is at [2].

[1] http://feeds.feedburner.com/fauskesnetnotebook
[2] https://code.google.com/p/dot2tex/
Comment 3 Justin Lecher (RETIRED) gentoo-dev 2014-03-07 14:22:56 UTC
+*pydot-1.0.28-r2 (07 Mar 2014)
+
+  07 Mar 2014; Justin Lecher <jlec@gentoo.org> pydot-1.0.28-r1.ebuild,
+  +pydot-1.0.28-r2.ebuild, +files/pydot-1.0.28-pyparsing2fix.patch,
+  metadata.xml:
+  Get patch from Fedora to fix compatibility with dev-python/pyparsing-2.0.1,
+  #490426
+
Comment 4 Steven Trogdon 2014-03-25 16:13:48 UTC
This fixes

>>> import dot_parser

but 

>>> from dot2tex import dotparsing

still fails for the same above reason. This has been reported upstream

https://code.google.com/p/dot2tex/issues/detail?id=38&colspec=ID%20Type%20Status%20Priority%20Milestone%20Owner%20Stars%20Summary