Hyphen in node id causes syntax error

0 votes
asked Aug 10, 2021 in Question / help by escovedo (140 points)

When i tried to draw some network diagram with nwdiag, it results in Syntax error if i have hyphens in network or node id, such like :



nwdiag {

  network network1 {

    address = ""

    node-1 [address=""];

    node2 [address=""];

    node3 [address=""];





When the hyphens are removed or replaced with underscore, it works.

The problem for me is that the network i am not trying has hyphen/dashes in its network or node names.

Anyone can help me to draw it without changing real-life network/node names ?


commented Aug 10, 2021 by Serge Wenger Work (15,040 points)

Hello, you can use description:

[Click on image to see the code]

commented Aug 10, 2021 by escovedo (140 points)

Thanks Serge.

Now it works!

Please bear with me for another question but very similar.

What about network id?

I tried to do same thing either for network id.

It doesnt cause error but nothing changed. Is there any good way to include hyphen in network name?

nwdiag {

  network network1 {

    address = ""

    description = "network-1"

    node1 [address="", description = "node-1"];

    node2 [address=""];

    node3 [address=""];



commented Aug 11, 2021 by escovedo (140 points)
Thanks again for your response , Serge.

Do i need to change the category of this pose to 'Bug'? or had better to wait for acknowledgement of plantuml team?

(I am not really familiar yet with this community how i should handle issues)

1 Answer

0 votes
answered Aug 23, 2021 by plantuml (289,640 points)
Many thanks for the report.
This is fixed in last beta http://beta.plantuml.net/plantuml.jar and on the online server.

Tell us if it's not working for you!

commented Aug 24, 2021 by escovedo (140 points)
Hello plantuml team
Now it works fine!
The issue solved.
Thanks a lot!