Skip to content

Commit

Permalink
fix: respect Python version of bento (#1130)
Browse files Browse the repository at this point in the history
  • Loading branch information
bojiang authored Jan 13, 2025
1 parent e357af2 commit fa6a74b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/openllm/venv.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ def _ensure_venv(venv_spec: VenvSpec) -> pathlib.Path:

venv_py = venv / 'Scripts' / 'python.exe' if os.name == 'nt' else venv / 'bin' / 'python'
try:
run_command(['python', '-m', 'uv', 'venv', venv], silent=VERBOSE_LEVEL.get() < 10)
run_command(
['python', '-m', 'uv', 'venv', venv, '-p', venv_spec.python_version], silent=VERBOSE_LEVEL.get() < 10
)
run_command(
['python', '-m', 'uv', 'pip', 'install', '-p', str(venv_py), 'bentoml'],
silent=VERBOSE_LEVEL.get() < 10,
Expand Down

0 comments on commit fa6a74b

Please sign in to comment.