Soren Daugaard
08/31/2023, 7:38 PMPrefectFutureMarvin
08/31/2023, 7:39 PMPrefectFuturePrefectFuture.submit()PrefectFuturePrefectFuture.is_done()TrueFalsePrefectFuture.resultNonepython
from prefect import Flow, task
@task
def do_something():
    # Your task logic here
    pass
with Flow("My Flow") as flow:
    future = do_something.submit()
# Check if the task has completed
if future.is_done():
    # Get the result of the task
    result = future.resultSoren Daugaard
09/01/2023, 5:55 PMAttributeError: 'PrefectFuture' object has no attribute 'is_done'Marvin
09/01/2023, 5:55 PMis_donePrefectFuturestatePrefectFuturestatePendingRunningSuccessFailedpython
from prefect import Flow, task
@task
def do_something():
    # Your task logic here
    pass
with Flow("My Flow") as flow:
    future = do_something.submit()
# Check the state of the task
if future.state.is_successful():
    # Get the result of the task
    result = future.resultis_successful()StateTrueFalse