Skip to content

locust/webui/dist/index.html script errors. #2753

Closed
@spatel-glsauto

Description

Prerequisites

Description

I'm on version 2.28.0. When I run locust.exe, I open up localhost:8089 in chrome. The page appears blank. Opening developer tools, I saw the following:

  1. Failed to load module script: Expected a JavaScript module script but the server responded with a MIME type of "text/plain". Strict MIME type checking is enforced for module scripts per HTML spec.
    a. Modifying the mime type from "module" to "application/javascript" fixed this error.

  2. Minified React error Inconsistent stats resetting #299; visit https://reactjs.org/docs/error-decoder.html?invariant=299
    a. Moving the first script tag out of <head> to right after the inline script fixed this error.

Command line

locust.exe

Locustfile contents

from locust import HttpUser, task
class HelloWorldUser(HttpUser):
    @task
    def hello_world(self):
        self.client.get("about:blank/")

Python version

3.10.11

Locust version

2.28.0

Operating system

Microsoft Windows 10 Enterprise

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions