Skip to main content
Filter by
Sorted by
Tagged with
6 votes
1 answer
9k views

This is my first time writing a locustfile, and I am trying to implement websocket load testing with locust. I have basically copied and pasted this example code from the locust plugin, https://github....
1 vote
0 answers
55 views

Locust does not log success in case of GRPC endpoint returning a stream Below is my setup: locust==2.33 python grpcio==1.70.0 grpcio-tools==1.62.1 protobuf==4.25.3 I am unable to see success on ...
2 votes
2 answers
575 views

Using locust load testing framework I need to call a single HTTP GET API with given pre defined rate and the through put should be always given requests per second rate. But according to the below ...
1 vote
0 answers
39 views

I am testing my Python Flask app using Locust to load-test a POST request with an .xlsx file attachment. However, I consistently encounter a 503 Service Unavailable error. This issue ONLY occurs when ...
1 vote
0 answers
38 views

Is there a way to compute proper percentiles in Locust? The values are always rounded off to a multiple of 10. I have read about Locust only estimating percentiles to save resources. But is there a ...
3 votes
1 answer
416 views

I'm using locust 2.29.1 for my performance tests. It works fine on Python 3.11.8 but now I'm trying to move to Python 3.12.4 and can't debug because it's freezing on the line with import locust. ...
1 vote
0 answers
46 views

I’m performing a WebSocket load test using Locust with websocket-client and a Flask webhook that receives transcripts. The WebSocket connection works, audio chunks are sent correctly, and my backend ...
12 votes
3 answers
10k views

What do you think is it possible to perform Load testing using PyTest? For example: import locust class UsersTest(locust.TaskSet): @locust.seq_task(1) def api_get_task(self): self....
4 votes
3 answers
2k views

I am trying to run locust using pytest. I have created this python file but it is not showing any output. pytest doesnot collect the test. How can I use locust with pytest from locust import HttpUser, ...
6 votes
2 answers
484 views

Trying to use locust following the documentation, https://docs.locust.io/en/stable/quickstart.html from locust import HttpUser, task class TestUser(HttpUser): # @task(1) # def health(self): ...
4 votes
1 answer
286 views

What's the correct / best way to perform costly per-process initialisation when using multiple workers, ensuring the workers can correctly communicate with the master? As part of a custom locustfile....
0 votes
0 answers
21 views

i am using locust for load testing of one of the API of create order, but I am facing the issue on the terminal its showing that particular API reqs this number of time but when I am checking on ...
1 vote
1 answer
61 views

I want to compare API response for two base URLs, comparing the monolithic vs micro architecture performance, but my code keeps picking up only the 1 url and doesn't create any hits for other URL as ...
0 votes
0 answers
34 views

I have the following tasks in locustfile tasks ={task1:1, task2:1,task3:1, task4:1,task5:1, task6:1} And trying to run each one in parallel by running locust with 6 users (so there is one task run by ...
0 votes
0 answers
38 views

enter image description hereI followed steps mentioned in https://docs.locust.io/en/stable/installation.html for installing locust. But I am getting the error ('locust' is not recognised as an ...
0 votes
3 answers
2k views

I am trying to load test a HTTP URL(Dynamic) using Locust.io. I already have the python scripts that will make a GET call to the URL. The challenge i am facing is, the urls and the number of users are ...
1 vote
1 answer
649 views

Can someone help determining what I am doing wrong with having --exit-code-on-error? python -m locust.main -f tt/tt_test.py -H http://thuis:8088/public --no-web --clients=3 --hatch-rate=1 --run-time=...
2 votes
0 answers
1k views

I am trying to do load testing using locust for FastAPI application using gunicorn below is my load testing code from locust import HttpUser, task, between file_path = "file_path" class ...
1 vote
1 answer
152 views

I get a response (using postman) in the following format when I make a POST request (and I am passing the payload when i make this POST request). [{"id":22,"name":tom,"age&...
0 votes
1 answer
69 views

I am using Locus in distributed mode with 1 master and n workers to run a load test. I am also using the locust-plugins library to utilize its Distributor utility. My goal is to preallocate one unique ...
3 votes
3 answers
2k views

We are trying to run the automation tests written in robot framework in parallel using locust. As of now, we have been able to run the robot-framework test file through locust by using the robot-...
0 votes
0 answers
45 views

I'm using Locust (version 2.32.3) to simulate multiple users performing work. I have a specific scenario I'd like to achieve clearly and efficiently: All users perform their workload repeatedly. At a ...
-3 votes
1 answer
102 views

I using python locust to do load test and my questions is i try to write csv file with email address as new row but it is separated the email charaters with ',' with each chracter like below: z,b,r,X,...
1 vote
1 answer
2k views

Is there a working example where we have bidirectional communication of grpc with locust performance testing tool. I don't see much working examples online where we have grpc with locust especially ...
0 votes
0 answers
25 views

Right now I'm trying to test out a new deep learning model on my local server using Locust. My local server uses a A6000 NVIDIA GPU which has around 46GB of VRAM. The problem is our production model ...
1 vote
0 answers
52 views

I am looking for a way, where for the below code next user comes in action only if current user is done with all of the tasks mentioned in a sequence. That is user should not be switched unless all ...
1 vote
2 answers
215 views

Trying to write a simple load test with locust. I just a have a single api which calls an endpoint get some data. The endpoint requires some credentials, lets say Http Basic auth. I'm running this ...
5 votes
2 answers
15k views

Looking at load testing tools, I found Locust and immediately found it appealing as a Python guy, but I'm not entirely sure if I can achieve the following scenario with it... I'm tasked with load ...
-2 votes
1 answer
158 views

I had coded some simple locust load testing code in python. Previously, it running without any errors but after some time i run the code, the http request is not get executed. class WebsiteUser(...
0 votes
0 answers
46 views

stages = [ { "name": "BigOrderUser Test", "duration": 400, # 10 minutes "users": 1, "spawn_rate&...
0 votes
1 answer
51 views

I am trying to do a distributed load generation and coordinate data between workers. There is an example of communicating across nodes from official Locust docs: https://github.com/locustio/locust/...
0 votes
0 answers
37 views

I am trying to setup Locust for generating load (in a distributed manner) for my service. I am using a custom shape to ramp up the traffic, sustain it for a time period and then ramp down. Now my use ...
1 vote
1 answer
291 views

I'm attempting to distribute a list of pre-defined request payloads across all the Users which are spawned in my run. Conceptually I want to split my list of N requests across U Users, such that each ...
0 votes
1 answer
115 views

I'm using configparser to read below values in a sample text file named config.txt: cookie='StaticWebAppsAuthCookie=GKeVpelA4wK+udvu7de737v7v8cv8v' Accept='*/*' Accept-Encoding=' gzip, deflate, br' ...
6 votes
2 answers
9k views

I want to load test my get request which is http://localhost:8080/v1/synonyms/project/?keyword=dealer and test method is @task(2) def get_synonym(self): response = self.client.get("/v1/synonyms/...
0 votes
1 answer
133 views

I want to write a locustfile for load testing. There is a local host on my system which I want to test (A social network called Oxwall). I need the user to login to Oxwall and then do some tasks, but ...
1 vote
0 answers
115 views

I am using Locust for performance testing, and I have a task that performs an API call in the on_start method. The on_start method prints the "started" message, but the request inside the ...
0 votes
1 answer
237 views

This command works fine locust --headless --users 10 --spawn-rate 1 -H http://localhost:3000 locustfile.py looks like that from locust import HttpUser, task class HelloWorldUser(HttpUser): @task ...
1 vote
0 answers
250 views

I'm running locust in distributed node with logs. The worker attempted to send more than 10 log lines in one interval. Further log sending was disabled for this worker. The worker logs do not land ...
1 vote
2 answers
477 views

I'm trying to add 98% in the locust report. The percentage is calculated by the application, in appears in the terminal. I just want it to appear in the html report next to the others. Any ideas on ...
0 votes
0 answers
87 views

I wanted to perform some load testing on Hana database. For this I decided to use Locust and I referenced the implementation given in this link for another database: https://community.cratedb.com/t/...
2 votes
4 answers
9k views

I am using locust package which uses python. I am following this tutorial: https://docs.locust.io/en/latest/quickstart.html#example-locustfile-py But when i get to executing this code in command ...
1 vote
0 answers
30 views

I am trying to simulate a form submission using Locust in Python. When manually submitting the form in a browser with incomplete data, I see the expected validation message: "Please make sure all ...
0 votes
1 answer
93 views

I have a Locust test that executes a flow of steps: @task def execute_tasks(): test = TestFlow(self.client) test.step1() test.step2() ... One of the steps involves polling for a status: ...
0 votes
0 answers
38 views

We run a loadtest with 119 tasks and weights ranging from 600000 to 2000. Average response time for the requests ranges from 500ms up to 3s. Our test infrastructure has 100VMs with 32 cores. We run ...
0 votes
1 answer
133 views

I am running Locust tests using distributed load generation with the flag: --processes -1 I used to get the stats while the tests were running from from locust.stats import ...
-1 votes
1 answer
60 views

I am working on a Ubuntu desktop and try to run load testing to check our server sites capacity. Usually my load testing is of 500 to 2000 users with the time range of 4 to 12 hours. And ...
0 votes
2 answers
81 views

Let's say that my test case is to get list of articles at news site and make a comment for the articles. Here is how my code may look: class MyTasks(TaskSet): def post_comment(self. article_id: int):...
0 votes
0 answers
135 views

I have two user classes: SyncUser NormalUser with the following code: class syncUser(HttpUser): host = '<hostname>' def on_start(self): self.userId = getsyncPullUser() ...
1 vote
1 answer
414 views

I'm trying to load test an API whose response exposes some additional custom metrics and attributes which aren't fully controllable from the request side but are known to correlate with performance: ...

1
2 3 4 5
19