fix: uv pip install fails outside venv in setup wizard

uv pip install requires a virtual environment by default. When hermes
is installed system-wide or via pipx, the setup wizard's SDK installs
(daytona, swe-rex[modal], tinker-atropos) fail with 'No virtual
environment found'. Fix by passing --python sys.executable to uv,
which targets the correct Python regardless of venv state.

Also show the actual error message on install failure so users can
debug.
This commit is contained in:
teknium1 2026-03-06 21:55:33 -08:00
parent 99bd69baa8
commit 9dac85b069
2 changed files with 5 additions and 3 deletions

View file

@ -260,7 +260,7 @@ def _run_post_setup(post_setup_key: str):
uv_bin = shutil.which("uv")
if uv_bin:
result = subprocess.run(
[uv_bin, "pip", "install", "-e", str(tinker_dir)],
[uv_bin, "pip", "install", "--python", sys.executable, "-e", str(tinker_dir)],
capture_output=True, text=True
)
else: