Skip to content

Commit

Permalink
fix: check if override_user_weights is empty or None
Browse files Browse the repository at this point in the history
  • Loading branch information
tdadela committed Nov 7, 2024
1 parent e082ee6 commit bbf8b01
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions locust/env.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,9 @@ def __init__(
self.worker_logs: dict[str, list[str]] = {}
"""Captured logs from all connected workers"""

for user_dict in override_user_weights:
self.update_user_class(user_dict)
if override_user_weights:
for user_dict in override_user_weights:
self.update_user_class(user_dict)

self._remove_user_classes_with_weight_zero()
self._validate_user_class_name_uniqueness()
Expand Down

0 comments on commit bbf8b01

Please sign in to comment.