Thread
#prefect-community
    h

    Hugo Polloli

    6 months ago
    Hi, I have chained tasks that are simply database operations, they don't return anything but they have to be run in a specific order. To this day I've simply used a boolean, I
    return True
    and pass it, unused, to the next task. Is that ok or did I miss a way to do that more "beautifully" in the docs ? (I don't find it particularly bad, + with the fact that I suffix it with "_done" I think it's explicit, but was still wondering)
    t1_done = task1()
    t2_done = task2(t1_done)
    ....
    Sylvain Hazard

    Sylvain Hazard

    6 months ago
    Hey ! The recent 1.1.0 release might have what you're looking for : the `.pipe` operator. It makes this kind of use case a bit more readable from a developer perspective.
    t

    Tomer Cagan

    6 months ago
    You can specify upstream tasks. Look here https://docs.prefect.io/core/advanced_tutorials/task-guide.html under "You can specify non-data dependencies with the functional API"
    h

    Hugo Polloli

    6 months ago
    Thanks to you both ! Looks like I was right to ask for a more beautiful way of doing, I'll see which one of these best applies to my case Thanks again