Thread
#prefect-community
    Gabriel Milan

    Gabriel Milan

    6 months ago
    Hello there! Is there a way of retrieving the current flow labels during execution? My guess would be that this is available on the
    context
    , but I can't seem to find it. I'm trying to use the
    prefect.tasks.prefect.create_flow_run
    using the very same labels as the parent flow, maybe there's a shortcut for it.
    Kevin Kho

    Kevin Kho

    6 months ago
    I think this is not in the context, and I think you’d need to need to query the GraphQL API actually.
    Let me check FlowRunView if it’s there. That might be easier than querying the API
    You can create a FlowRunView and then pull the labels attribute
    Gabriel Milan

    Gabriel Milan

    6 months ago
    amazing! is there a snippet for this or something?
    Kevin Kho

    Kevin Kho

    6 months ago
    Gabriel Milan

    Gabriel Milan

    6 months ago
    thank you very much!