Skip to content

Replace deprecated request_success() and request_failure() with request() from locust.event.Events.request #12

@thx123

Description

@thx123

The deprecated request_success() and request_failure() are already removed in locust.event.Events.request upstream, causing the following error:

File "/Users/htie/coding/redis-load-test/Scripts/redis_get_set.py", line 88, in get_time self.client.query(self.key) File "/Users/htie/coding/redis-load-test/Scripts/redis_get_set.py", line 50, in query events.request_success.fire(

The fix is to simply relace them with request() method name, per:
https://stackoverflow.com/questions/76016708/locust-events-object-has-no-attribute-request-success

Verified working with load tests, after the fix, the errors are gone, and all graphs are displayed properly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions