Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lost edge #134

Closed
JonNeat opened this issue May 17, 2018 · 6 comments
Closed

Lost edge #134

JonNeat opened this issue May 17, 2018 · 6 comments

Comments

@JonNeat
Copy link

JonNeat commented May 17, 2018

Hi everyone.

The following graph gives a fatal error (lost b7bce8ef-4a83-450c-9127-e0e3ebe28a15 8095007b-5433-4d6f-90f7-583cd2017b35 edge) and cannot be drawn. If you remove any edge or node it works.
I hope you can help me understand the issue.

digraph X {
rankdir=LR;
graph [fontsize="10", fontname=Verdana];
node [shape=record, fontsize="10", fontname=Verdana];
subgraph cluster_0 {
node [style=filled];
color="#ef882f";
label=c0;
"b7bce8ef-4a83-450c-9127-e0e3ebe28a15" [label=X, tooltip=X, URL="/system/show.php?id=b7bce8ef-4a83-450c-9127-e0e3ebe28a15"];
}
subgraph cluster_2 {
node [style=filled];
color=blue;
label=c2;
"bbae94c9-ca7a-4671-94b8-531893c0db49" [label=Y, tooltip=Y, URL="/system/show.php?id=bbae94c9-ca7a-4671-94b8-531893c0db49"];
"56ffb2fc-aa57-41ef-bbbc-05679cb3ef07" [label=Z, tooltip=Z, URL="/system/show.php?id=56ffb2fc-aa57-41ef-bbbc-05679cb3ef07"];
}
subgraph cluster_3 {
node [style=filled];
color=blue;
label="c3";
"64831351-d39f-4be0-8757-fcdf20ce6cf1" [label=A, tooltip=A, URL="/system/show.php?id=64831351-d39f-4be0-8757-fcdf20ce6cf1"];
"9ba87b4a-c017-4157-842c-c85f525c82be" [label=B, tooltip=B, URL="/system/show.php?id=9ba87b4a-c017-4157-842c-c85f525c82be"];
}
subgraph cluster_6 {
node [style=filled];
color=blue;
label=c6;
"104b66db-0034-4436-9d1f-bc7e8e26a49c" [label=C, tooltip=C, URL="/system/show.php?id=104b66db-0034-4436-9d1f-bc7e8e26a49c"];
"6377e1ae-d5d3-4119-a2c4-a01bddd40d58" [label=D, tooltip=D, URL="/system/show.php?id=6377e1ae-d5d3-4119-a2c4-a01bddd40d58"];
}

"64831351-d39f-4be0-8757-fcdf20ce6cf1" -> "bbae94c9-ca7a-4671-94b8-531893c0db49";
"b7bce8ef-4a83-450c-9127-e0e3ebe28a15" -> "8095007b-5433-4d6f-90f7-583cd2017b35";
"b7bce8ef-4a83-450c-9127-e0e3ebe28a15" -> "104b66db-0034-4436-9d1f-bc7e8e26a49c";
"8095007b-5433-4d6f-90f7-583cd2017b35" -> "6377e1ae-d5d3-4119-a2c4-a01bddd40d58";
"8095007b-5433-4d6f-90f7-583cd2017b35" -> "be75b8f9-7f50-4785-9ea7-2f1f7492e696";
"be75b8f9-7f50-4785-9ea7-2f1f7492e696" -> "9ba87b4a-c017-4157-842c-c85f525c82be";
"56ffb2fc-aa57-41ef-bbbc-05679cb3ef07" -> "b7bce8ef-4a83-450c-9127-e0e3ebe28a15";

}

@magjac
Copy link

magjac commented May 17, 2018

For the record: It works with stand-alone dot version 2.36.0 and 2.38.0. Viz.js uses 2.40.1, but neither @JonNielsen nor me had access to dot at that version, so we couldn't tell if dot is broken after 2.38.0 or if it is the Emscripten port that is broken.

Increasing the memory to 52 MB didn't help either.

@mdaines
Copy link
Owner

mdaines commented May 17, 2018

I get these messages from dot 2.40.1 when I try to render this graph:

Warning: flat edge between adjacent nodes one of which has a record shape - replace records with HTML-like labels
  Edge 8095007b-5433-4d6f-90f7-583cd2017b35 -> b7bce8ef-4a83-450c-9127-e0e3ebe28a15
Error: lost b7bce8ef-4a83-450c-9127-e0e3ebe28a15 8095007b-5433-4d6f-90f7-583cd2017b35 edge

Viz.js considers this an error and causes the promise to reject, but dot will still produce output. See #123.

I don't know if changing the node shape to something else will have the stylistic effect you want or not, but it should fix the error.

@mdaines
Copy link
Owner

mdaines commented May 17, 2018

Here's the output. The first rendering uses the record shape. The second omits it. Notice that there is a missing edge from "X" to "8095..." in the first case.

test dot

test dot-norecord

@JonNeat
Copy link
Author

JonNeat commented May 17, 2018

@mdaines

Thank you for taking your time to reply. I'll try testing it tomorrow morning and give feedback. 👍

@JonNeat
Copy link
Author

JonNeat commented May 18, 2018

You were right @mdaines. It was solved by removing "record" as shape.

@mdaines
Copy link
Owner

mdaines commented May 18, 2018

@JonNielsen Thanks for confirming that it works.

I think Viz.js will continue to reject promises for graphs like this. It might be nice in some cases to be able to get at the output as suggested in #123, however.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants