Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
Signed-off-by: Tyler Gu <[email protected]>
  • Loading branch information
tylergu committed Nov 13, 2023
1 parent c47bc22 commit 25de78b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion performance_measurement/check_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def check_tolerations(
def check_affinity(desired_affinity: dict, sts_object: k8s_models.V1StatefulSet) -> bool:
# check if affinity match
current_affinity = sts_object["spec"]["template"]["spec"]["affinity"]
if desired_affinity is None or desired_affinity == {}:
if desired_affinity is None or len(desired_affinity) == 0:
return current_affinity is None or current_affinity == {}
deepdiff = DeepDiff(desired_affinity, current_affinity, ignore_order=True)
if deepdiff:
Expand Down

0 comments on commit 25de78b

Please sign in to comment.