HI all, I'm new to prefect, loving it so far. I'm ...
# prefect-community
c
HI all, I'm new to prefect, loving it so far. I'm working on a 1.0 project that I've inherited - I was wondering if there is a way to utilize the graphql api to verify that all downstream tasks (including children of children etc) of a particular task run were successful. I can do it via repeated querying for downstream_task info, but it would be nice if there was some other method that didn't involve hitting the api repeatedly. Thanks.
1
m
Hey @chris arettines if I'm understanding you correctly I think the easiest way to do this would actually be to query for the flow_run and include the task runs related to it, so something like this which could likely be modified to return the relevant information you might want/need
Copy code
query {
  flow_run {
    id
    name
    task_runs {
      details {
        id
        state 
        }
      }
    }
  }
c
Hi Mason, thanks for the reply. I will look into that. What I effectively want is to be able to answer the question "has this subflow (defined by a given flow task as the root node and all downstream dependencies) succeeded?"