From f1a86223862614aae64f0cd8b57759e5d79bf19e Mon Sep 17 00:00:00 2001 From: Bobbins228 Date: Wed, 27 Mar 2024 19:54:31 +0000 Subject: [PATCH] Review changes: conditionals --- src/codeflare_sdk/cluster/cluster.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/codeflare_sdk/cluster/cluster.py b/src/codeflare_sdk/cluster/cluster.py index 8aebf42b2..af8b6f6de 100644 --- a/src/codeflare_sdk/cluster/cluster.py +++ b/src/codeflare_sdk/cluster/cluster.py @@ -515,14 +515,14 @@ def from_k8_cluster_object( else: local_interactive = False if "codeflare.dev/oauth" in rc["metadata"]["annotations"]: - if rc["metadata"]["annotations"]["codeflare.dev/oauth"] == "True": - openshift_oauth = True + openshift_oauth = ( + rc["metadata"]["annotations"]["codeflare.dev/oauth"] == "True" + ) else: for container in rc["spec"]["headGroupSpec"]["template"]["spec"][ "containers" ]: - if "oauth-proxy" in container["name"]: - openshift_oauth = True + openshift_oauth = "oauth-proxy" in container["name"] machine_types = ( rc["metadata"]["labels"]["orderedinstance"].split("_") if "orderedinstance" in rc["metadata"]["labels"]