From d514484067d12bce19a988a121db67cbbbc3dcef Mon Sep 17 00:00:00 2001 From: Yun Wu Date: Mon, 19 Aug 2024 12:29:23 -0700 Subject: [PATCH] Remove redundant generateName --- metaflow/plugins/aip/aip.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/metaflow/plugins/aip/aip.py b/metaflow/plugins/aip/aip.py index 1d81a697e65..04b7af03bb5 100644 --- a/metaflow/plugins/aip/aip.py +++ b/metaflow/plugins/aip/aip.py @@ -291,10 +291,9 @@ def _create_workflow_yaml( # Note the name has to follow k8s format. # self.name is typically CamelCase as it's python class name. # generateName contains a sanitized version of self.name from aip.compiler + default_workflow_name = workflow["metadata"].pop("generateName").rstrip("-") workflow["metadata"]["name"] = ( - sanitize_k8s_name(name) - if name - else workflow["metadata"].pop("generateName").rstrip("-") + sanitize_k8s_name(name) if name else default_workflow_name ) # Service account is added through webhooks.