Question on dynamically creating flows; Say I hav...
# prefect-server
a
Question on dynamically creating flows; Say I have 3 tasks
Copy code
@task
def task_1():
  print('1')

@task
def task_2():
  print('2')

@task
def task_3():
  print('3')
And I wanted to give the user the ability to say in which order these should be executed, or who should consume which one. i.e. I want to user to describe a graph of these callables and then for the flow to execute them. How would I do this?
k
I think you can’t in Prefect 1 because it violates the DAG model. You could in Prefect 2 though
a
Understood, mostly interested in prefect 2! 🙂 any tips?
k
You can do this as you would in normal Python pretty much