<@ULVA73B9P> Can you please confirm what type of p...
# ask-marvin
s
@Marvin Can you please confirm what type of prefect states according to your https://docs.prefect.io/v3/concepts/states#state-types docs do these two mutually exclusive sets may contain:
Copy code
from prefect.futures import wait
finished, not_done = wait(futures_list)
m
thought for 256.4 seconds
Short answer: - finished (aka done): futures whose state type is final — COMPLETED, FAILED, CRASHED, or CANCELLED - not_done: futures in any non-final state type — SCHEDULED, PENDING, RUNNING, PAUSED, or CANCELLING Notes: -
wait
returns a named tuple
(done, not_done)
, so your
finished, not_done = wait(futures_list)
aligns with that ordering. - Final vs non-final is defined in the Prefect 3.x state types table: https://docs.prefect.io/v3/concepts/states#state-types - API ref for `wait`: https://docs.prefect.io/v3/api-ref/python/prefect-futures#prefect.futures.wait Examples of state names that map to these types: - Final: Completed/Cached/RolledBack → COMPLETED; Failed/TimedOut → FAILED; Crashed → CRASHED; Cancelled → CANCELLED - Non-final: Scheduled/Late/AwaitingRetry/AwaitingConcurrencySlot/Resuming → SCHEDULED; Pending → PENDING; Running/Retrying → RUNNING; Paused/Suspended → PAUSED; Cancelling → CANCELLING