Skip to content

Commit

Permalink
provide warning for yarn presence
Browse files Browse the repository at this point in the history
  • Loading branch information
mquinnfd committed Jul 10, 2024
1 parent 54a8b3d commit f7a142e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pre_build.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
import os
import subprocess
from shutil import which
from sys import exit


def build() -> None:
if which("yarn") is None:
print("Locust requires the yarn binary to be available in this shell to build the web front-end.\nSee: https://docs.locust.io/en/stable/developing-locust.html#making-changes-to-locust-s-web-ui")
exit(1)
if os.environ.get("SKIP_PRE_BUILD", "") == "true":
print("Skipping front end build...")
return
Expand Down

0 comments on commit f7a142e

Please sign in to comment.