Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Log locust version earlier #2904

Merged
merged 1 commit into from
Sep 15, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions locust/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,8 @@ def is_valid_percentile(parameter):
sys.exit(1)

children = []
logger = logging.getLogger(__name__)
logger.info(f"Starting Locust {version}")

if options.processes:
if os.name == "nt":
Expand Down Expand Up @@ -298,7 +300,6 @@ def kill_workers(children):

atexit.register(kill_workers, children)

logger = logging.getLogger(__name__)
greenlet_exception_handler = greenlet_exception_logger(logger)

if options.stop_timeout:
Expand Down Expand Up @@ -686,7 +687,6 @@ def save_html_report():
gevent.signal_handler(signal.SIGTERM, sig_term_handler)

try:
logger.info(f"Starting Locust {version}")
if options.class_picker:
logger.info("Locust is running with the UserClass Picker Enabled")
if options.autostart and not options.headless:
Expand Down