locustio / locust

Write scalable load tests in plain Python 🚗💨
https://locust.cloud
MIT License
25.06k stars 2.99k forks source link

print statements are not appearing on console when -n is 1 #750

Closed contactparthshah closed 6 years ago

contactparthshah commented 6 years ago

Description of issue / feature request

locust -f ./local_file.py --no-web -c 5 -r 1 -n 1 In local_file.py, I have put few print statements which doesn't appear on console when -n 1 but for greater than 1 it comes.

Expected behavior

It should print statment on console.

Actual behavior

Its not printing statement on console. TBD

Environment settings (for bug reports)

Steps to reproduce (for bug reports)

TBD - example code appreciated

cgoldberg commented 6 years ago

I have put few print statements which doesn't appear on console when -n 1 but for greater than 1 it comes

Setting n or --num-requests sets the number of requests to send before stopping execution, so you are telling it to stop immediately after 1 request (possibly before all locusts are spawned).

FWIW, the --num-requests option has been removed in Locust 0.9 in favor of time based execution.

contactparthshah commented 6 years ago

Looks like that is the issue

contactparthshah commented 6 years ago

Could you please tell me how can i download 0.9 version as while doing pip install locustio, 0.8.1 version got installed

cgoldberg commented 6 years ago

0,9 has not been released. you can however install latest master branch with this change

contactparthshah commented 6 years ago

Thank you