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

[ModernUI] HTML entities are incorrectly escaped in generated report #2635

Closed
2 tasks done
sino1641 opened this issue Mar 14, 2024 · 0 comments · Fixed by #2648
Closed
2 tasks done

[ModernUI] HTML entities are incorrectly escaped in generated report #2635

sino1641 opened this issue Mar 14, 2024 · 0 comments · Fixed by #2648
Labels

Comments

@sino1641
Copy link

sino1641 commented Mar 14, 2024

Prerequisites

Description

Description

I've encountered an issue where the greater-than symbols (>) in the Locust Web UI report are being rendered as their HTML entity equivalents (>). This issue occurs when downloading the report, which should display these symbols correctly.

Expected Behavior

The downloaded report should display the > symbol as it is, without converting it to the > HTML entity.

Actual Behavior

When I download the report from the Locust Web UI, all instances of the > symbol are being converted to >, which is not the expected output.

Steps to Reproduce

  1. Run a Locust test with the Web UI enabled.
  2. After the test, go to the 'Download Data' tab.
  3. Click on 'Download' to get the report.
  4. Open the downloaded report and observe that the > symbols are replaced with >.

Command line

locust -f mylocustfile.py

Locustfile contents

Class User():
    def addCustomSuccessEntryToStatistics(self, name: str, requestType: str, responseTime: int, responseLength: int = 0) -> None:
        self.__addCustomEntryToStatistics(name, requestType, responseTime, None, responseLength=responseLength)

def testcase():
    user.addCustomSuccessEntryToStatistics(f'A -> B', 'Scenario Progress', int(time.time() - start_time), responseLength=timeLeftInSeconds)

Python version

3.10.12

Locust version

2.24.0

Operating system

Ubuntu 2204

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

Successfully merging a pull request may close this issue.

1 participant