cogk / reacteur

Automation and computation toolbox for no-code development for Frappe / Dodock.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Data flow vs. Execution flow

cogk opened this issue · comments

It might be impossible to use a graph-based view for the execution flow.

Imagine the following graph, where the top-down axis is time.

flowchart TB

  trigger
  -->|values| x[change values]
  -->|values| y[new_doc + save]
  -->|doc| z[send PDF via email]

The problem is that no UI element prevents the users from adding a data dependency like doc --> values. A better way could be to have a timeline instead of a graph, where the lifetimes of objects are clearly presented.

flowchart TB

  trigger
  -->|values| x[change values]
  -->|values| y[new_doc + save]
  -->|doc| z[send PDF via email]

  z -->|doc.grand_total| y

linkStyle 3 stroke:red;

Because we want to constrain the time axis, and we only have a 2D screen, we have to remove free-movement in the time axis. We could disallow loops using clever algorithms but that might make it more confusing.

I was thinking of a timeline: actions below, and data above where the movement is constrained by a hidden line just after the block that provided the value.