design-first/system-designer

Error when viewing diagrams

nadavoid opened this issue · 2 comments

When trying to view the diagram of a very simple system, only an error message is displayed: "Error: syntax error in line 59 near '->'".

  • Downloaded from Mac App Store today
  • System Designer version number: v3.2.0
  • System Designer platform: macOS
  • OS version: macOS 10.14

I'm trying System Designer for the first time today, so it's very likely I'm missing something.

My sample Basic.json system, which contains one schema: Item, with one property: title.

{"name":"Basic","master":true,"version":"0.0.1","description":"","schemas":{"f8303787-00f6-40ed-b62b-079fb8fded2f":{"_id":"f8303787-00f6-40ed-b62b-079fb8fded2f","_name":"Item","_inherit":["_Component"],"title":"property"}},"models":{"ab0c5689-b840-432d-b1e3-91b20141d101":{"_id":"ab0c5689-b840-432d-b1e3-91b20141d101","_name":"Item","_description":"","title":{"description":"","type":"any","readOnly":false,"mandatory":false,"default":""}}},"behaviors":{"b022126b-a514-4996-b6e3-615b820d6c32":{"_id":"b022126b-a514-4996-b6e3-615b820d6c32","component":"a9cbf3e1-45ae-4076-a877-a3c4a0c4ca1e","state":"start","action":"function start() { \n  \n}","useCoreAPI":false,"core":false}},"types":{},"components":{"Item":{"f02ee5ce-d031-44f2-8c43-26446a17ec56":{"_id":"f02ee5ce-d031-44f2-8c43-26446a17ec56","title":"test"}}},"_id":"a9cbf3e1-45ae-4076-a877-a3c4a0c4ca1e"}

Thanks for the report.

When you get this error, generally it means that you used some keywords of the DOT language (i.e. node, edge, graph, digraph, subgraph, and strict) in schema or property name. But it is not the case in your system. So the diagram should be generated correctly.

In fact, I have tested your system and I get no error.

What you can do is to export your system in Graphviz format with System Designer, and send the file to see where the problem comes from.

Thanks for the quick reply!

A restart and a new day seems to have fixed this for me. Maybe something was stuck in a cache or something.

I did have a different system that had the word Node as a Schema name, which was throwing this error. Renaming it immediately fixed the error and I see a full diagram.

Thanks again for the help! I'll definitely make a note of those reserved words.