mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-07-29 15:23:51 +00:00
Fix #2 to help with testing packages
This commit is contained in:
parent
83adaae09b
commit
6441b78aac
1 changed files with 28 additions and 28 deletions
|
@ -8,7 +8,7 @@
|
|||
|
||||
LLAMA_MODELS_DIR=${LLAMA_MODELS_DIR:-}
|
||||
LLAMA_TOOLCHAIN_DIR=${LLAMA_TOOLCHAIN_DIR:-}
|
||||
USE_TEST_PYPI=${USE_TEST_PYPI:-}
|
||||
TEST_PYPI_VERSION=${TEST_PYPI_VERSION:-}
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
|
@ -57,12 +57,11 @@ ensure_conda_env_python310() {
|
|||
eval "$(conda shell.bash hook)"
|
||||
conda deactivate && conda activate "${env_name}"
|
||||
|
||||
PIP_ARGS=""
|
||||
if [ "$USE_TEST_PYPI" = "1" ]; then
|
||||
if [ -n "$TEST_PYPI_VERSION" ]; then
|
||||
# these packages are damaged in test-pypi, so install them first
|
||||
pip install fastapi libcst
|
||||
PIP_ARGS="--extra-index-url https://test.pypi.org/simple/"
|
||||
fi
|
||||
pip install --extra-index-url https://test.pypi.org/simple/ llama-toolchain==$TEST_PYPI_VERSION $pip_dependencies
|
||||
else
|
||||
# Re-installing llama-toolchain in the new conda environment
|
||||
if [ -n "$LLAMA_TOOLCHAIN_DIR" ]; then
|
||||
if [ ! -d "$LLAMA_TOOLCHAIN_DIR" ]; then
|
||||
|
@ -92,6 +91,7 @@ ensure_conda_env_python310() {
|
|||
echo "Installing pip dependencies: $pip_dependencies"
|
||||
pip install $PIP_ARGS $pip_dependencies
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
if [ "$#" -ne 3 ]; then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue