From b3d2c6a57edcb7b461150844cf072c96536ac430 Mon Sep 17 00:00:00 2001 From: pythongosssss <125205205+pythongosssss@users.noreply.github.com> Date: Fri, 20 Oct 2023 18:52:04 +0100 Subject: [PATCH] install deps --- .github/workflows/test-ui.yaml | 4 ++++ tests-ui/setup.js | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-ui.yaml b/.github/workflows/test-ui.yaml index 4861dfc5b..62b4c35f6 100644 --- a/.github/workflows/test-ui.yaml +++ b/.github/workflows/test-ui.yaml @@ -13,6 +13,10 @@ jobs: - uses: actions/setup-python@v4 with: python-version: '3.10' + - name: Install requirements + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt - name: Run Tests run: | npm install diff --git a/tests-ui/setup.js b/tests-ui/setup.js index 6419fbaa2..9cb2eb3af 100644 --- a/tests-ui/setup.js +++ b/tests-ui/setup.js @@ -50,10 +50,14 @@ async function setup() { console.log("Starting ComfyUI server..."); let python = resolve("../../python_embeded/python.exe"); - if (!existsSync(python)) { + let args; + if (existsSync(python)) { + args = ["-s", "ComfyUI/main.py"]; + } else { python = "python"; + args = ["main.py"]; } - child = spawn(python, ["-s", "ComfyUI/main.py", "--cpu"], { cwd: "../.." }); + child = spawn(python, [...args, "--cpu"], { cwd: "../.." }); child.on("error", (err) => { console.log(`Server error (${err})`); i = 30;