mirror of
https://github.com/theroyallab/tabbyAPI.git
synced 2026-03-14 15:57:27 +00:00
Start: Fix uv check
In Windows, checking for a command yields a FileNotFound error if the utility isn't found. This led to complicated logic which can be solved by using which instead. Signed-off-by: kingbri <8082010+kingbri1@users.noreply.github.com>
This commit is contained in:
10
start.py
10
start.py
@@ -8,15 +8,11 @@ import platform
|
||||
import subprocess
|
||||
import sys
|
||||
import traceback
|
||||
from shutil import copyfile
|
||||
from shutil import copyfile, which
|
||||
from typing import List
|
||||
|
||||
has_uv = (
|
||||
subprocess.run(
|
||||
["uv", "--version"], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL
|
||||
).returncode
|
||||
== 0
|
||||
)
|
||||
# Checks for uv installation
|
||||
has_uv = which("uv") is not None
|
||||
|
||||
start_options = {}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user