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

Update Stats History on HTML Report #2709

Merged
merged 1 commit into from
May 11, 2024

Conversation

andrewbaldwin44
Copy link
Collaborator

@andrewbaldwin44 andrewbaldwin44 commented May 11, 2024

The Issue

Because of HISTORY_STATS_INTERVAL_SEC, we will only have history starting after 5 seconds of run time. Unlike request_stats in web.py, we rely on history to display the charts in the HTML report. This is why the dashboard shows the results correctly in the dashboard but not in the report

Proposal

Expose a new function update_stats_history that can be called when generating the HTML report. This will ensure that the stats history list is up to date before returning the report

image

Fixes #2706

@cyberw
Copy link
Collaborator

cyberw commented May 11, 2024

Nice!

@cyberw cyberw merged commit 12e4f57 into locustio:master May 11, 2024
14 checks passed
@cyberw
Copy link
Collaborator

cyberw commented May 11, 2024

Some time we should add automated tests for this kind of thing. But not necessarily today :)

@andrewbaldwin44
Copy link
Collaborator Author

Definitely I think it's a good idea. I can look into it at some point with something like Playwright or Selenium.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The Charts presentation in the report downloaded by locust is problematic
2 participants