https://prefect.io logo
Title
v

Vipul

09/16/2020, 4:28 PM
Hi All, I created two flow with same name but different version_group_id. I am able to see both these flow name in UI but can't figure out what version_group_id it is, is there any way to identify...
j

josh

09/16/2020, 4:33 PM
Hi @Vipul I’m not sure if it is displayed prominently but you can query for the version group ID of your flow through the GraphQL / Interactive API with something like this:
query {
    flow(where: {id: {_eq: "FLOW_ID"}}) {
      version_group_id
  }
}
v

Vipul

09/16/2020, 4:37 PM
Thanks. Do you know what advantage version_group_id gives? I tried creating two flow with same name. The first one with version group as "1" for which the last tasks return result of 1. And then I register the same flow name with version group as "2" for which the last task return result of 2. And then when I run the flow with version group as "1", the last task return the result of 2 and not 1 as I expected.
j

josh

09/16/2020, 4:38 PM
What is the storage option you have set on your flow? By default it has Local storage and flows stored in the local filesystem go by
flow_name.prefect
so if you have two flows with the same name the second registration will overwrite the first
You can always set different paths for flows stored locally if you want them to have the same name https://docs.prefect.io/api/latest/environments/storage.html#local
v

Vipul

09/16/2020, 4:40 PM
Thanks, let me read