Graphviz Issue Tracker
Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002588graphvizOtherpublic2016-01-18 03:022016-02-09 14:16
Assigned To 
PlatformOSUbuntuOS Version14.04
Summary0002588: Mulitple duplicate node bug
DescriptionI have programmatically generated the attached large .dot file.

I compile it under Linux with

dot -Tps -o

However, the last declared node gets duplicated multiple times in the resulting graph (white circles in the linked .ps image, with label "res_582").
( [^])

I have tried dot, sfdp, fdp, twopi.

I suspect a bug in the dot compiler, but a second opinion wouldn't hurt.

Thanks in advance!

P.S. I removed all the individual node descriptions regarding label and then merged node declarations into the resulting 5 different node type groups (regarding shape and fillcolor). This resolved the issue of duplicate nodes appearing, but I lose the individual label functionality, which was useful to me.
Steps To ReproduceIn an Ubuntu terminal:

dot -Tps -o
TagsNo tags attached.
Attached Filesdot file icon (Attachment missing)
dot file icon (Attachment missing)

- Relationships

-  Notes
User avatar (0001015)
north (administrator)
2016-01-18 08:41

The sample graph has a long series of statements of the form:

    node [shape = box, fillcolor = cyan, style = filled, label="keq4
    34"]; keq4;
    node [shape = box, fillcolor = cyan, style = filled, label="keq5
    39"]; keq5;
ending in
    node [shape = circle, fillcolor = white, style = filled, label="res_582
    753"]; res_582;

Each statement sets the defaults for all new nodes, but only makes one node,
except the last one sets the defaults for all other nodes created afterward.
I think the intent was just to make one node and set its attributes, like this
    keq4 [shape = box, fillcolor = cyan, style = filled, label="keq4
    keq5 [shape = box, fillcolor = cyan, style = filled, label="keq5
    res_582 [shape = circle, fillcolor = white, style = filled, label="res_582

I don't have time to investigate further but this is almost certainly what went wrong,
not a bug in the graph parser.
User avatar (0001016)
Georacer (reporter)
2016-01-18 09:16

Thank you for your time, north.
Indeed, I may not have used the best coding. I have switched to your proposed notation and the problem does not occur anymore.

I don't understand the cause of the problem, i.e. if I used bad syntax. However, from my point of view, this ticket is solved.

If anyone else sees something more in this and wishes to investigate further, I'm willing to provide more info.
User avatar (0001028)
ellson (administrator)
2016-02-09 13:59

Sounds like you have this solved. Just wanted to add that you can use "node" in "subgraphs" to set common attributes, and still use individual attributes. I'll attach a more concise version of your graph using this technique,
User avatar (0001029)
Georacer (reporter)
2016-02-09 14:16

Thanks for the hint!

- Issue History
Date Modified Username Field Change
2016-01-18 03:02 Georacer New Issue
2016-01-18 03:02 Georacer File Added:
2016-01-18 08:41 north Note Added: 0001015
2016-01-18 09:16 Georacer Note Added: 0001016
2016-02-09 13:59 ellson Note Added: 0001028
2016-02-09 14:01 ellson File Added:
2016-02-09 14:16 Georacer Note Added: 0001029

MantisBT 1.2.5[^]
Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker