pombreda / pydot

Automatically exported from code.google.com/p/pydot
MIT License
0 stars 0 forks source link

dot_parse don't support brackets #4

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
This graph is parsed OK:
  a -> b
  a -> c
But this shortening don't work:
  a -> {b, c}

Original issue reported on code.google.com by Paul.Colomiets@gmail.com on 14 Jan 2008 at 4:11

GoogleCodeExporter commented 9 years ago
It will parse it ( in the latest tests it already does )

PS: The code is shaping up. It's taking forever to release the updated pydot 
because I embarked on rewriting 
pydot's core aiming at increasing performance and supporting some advanced 
constructs/expressions that 
weren't supported before. And that took a bit of thinking plus extensive 
regression tests. It will eventually see 
the light of day.

Original comment by ero.carr...@gmail.com on 21 Jan 2008 at 1:59

GoogleCodeExporter commented 9 years ago
Sorry it's my mistake, it parses comma not in same way as graphviz. But seems 
that
specification doesn't allow comma here. So following works:
  a -> {b c}
  a -> {b; c}

Sorry for the noise.

Original comment by Paul.Colomiets@gmail.com on 22 Jan 2008 at 6:48

GoogleCodeExporter commented 9 years ago
Well, I'm here again :)

There are problems with parsing other way around:
  {b; c} -> a
Error is:
  TypeError: unsupported operand type(s) for +: 'Subgraph' and 'str'

BTW, I've not found any unittests here. Is this something you do in private
repository? I'd like to help with tests and maybe some code (although I'm not
familiar with pyparsing yet).

Original comment by Paul.Colomiets@gmail.com on 28 Jan 2008 at 7:39

GoogleCodeExporter commented 9 years ago
Same with:
  a -> b -> {c; d}

Original comment by Paul.Colomiets@gmail.com on 28 Jan 2008 at 7:50

GoogleCodeExporter commented 9 years ago
All of those cases should be fixed in the ucoming 1.0.2. I've given the parsing 
code a good update. 

Regarding the unittests, I've put some together for this latest version. I 
don't think I'll include them in the main 
release (loads of .dot files) but let me know if you want them.

Original comment by ero.carr...@gmail.com on 14 Feb 2008 at 10:06