Skip to content

Commit

Permalink
adjust 'list_namespaced_persistent_volume_claim' to be called with ke…
Browse files Browse the repository at this point in the history
…yword argument

Signed-off-by: helenxie-bit <[email protected]>
  • Loading branch information
helenxie-bit committed Oct 9, 2024
1 parent e68fe38 commit d3a3404
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sdk/python/v1beta1/kubeflow/katib/api/katib_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -570,7 +570,7 @@ class name in this argument.
)
except Exception as e:
pvc_list = self.core_api.list_namespaced_persistent_volume_claim(
namespace
namespace=namespace
)
# Check if the PVC with the specified name exists.
for pvc in pvc_list.items:
Expand Down
2 changes: 1 addition & 1 deletion sdk/python/v1beta1/kubeflow/katib/api/katib_client_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def create_namespaced_persistent_volume_claim_response(*args, **kwargs):


def list_namespaced_persistent_volume_claim_response(*args, **kwargs):
if args[0] == "pvc creation failed":
if kwargs.get("namespace") == "pvc creation failed":
mock_pvc = Mock()
mock_pvc.metadata.name = "pvc_failed"
mock_list = Mock()
Expand Down

0 comments on commit d3a3404

Please sign in to comment.