Skip to content

Commit

Permalink
switch to pip
Browse files Browse the repository at this point in the history
  • Loading branch information
aakrem committed May 16, 2024
1 parent f724a4d commit 4edf551
Showing 1 changed file with 15 additions and 32 deletions.
47 changes: 15 additions & 32 deletions .github/workflows/agenta-cli-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,61 +20,44 @@ jobs:
with:
python-version: "3.12"

- name: Install Poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true

- name: Load cached venv
id: cached-poetry-dependencies
uses: actions/cache@v3
with:
path: .venv
key: venv-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
restore-keys: |
venv-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools
pip install poetry
cd agenta-cli
poetry install --no-interaction --no-root
pip install -e .
- name: Create .env file
run: |
echo "OPEN_API_KEY=${{ secrets.OPEN_API_KEY }}" > .env
working-directory: examples/baby_name_generator

- name: Run agenta init
env:
BACKEND_HOST: ${{ secrets.BACKEND_HOST }}
run: |
cd agenta-cli
source $(poetry env info --path)/bin/activate
cd ../examples/baby_name_generator
poetry run agenta init --app_name woooo --backend_host ${{ secrets.BACKEND_HOST }}
cd examples/baby_name_generator
agenta init --app_name woooo2 --backend_host ${{ secrets.BACKEND_HOST }}
shell: bash
continue-on-error: false

- name: Run agenta variant serve
env:
BACKEND_HOST: ${{ secrets.BACKEND_HOST }}
run: |
cd agenta-cli
source $(poetry env info --path)/bin/activate
cd ../examples/baby_name_generator
poetry run agenta variant serve --file_name app.py
cd examples/baby_name_generator
agenta variant serve --file_name app.py
shell: bash
continue-on-error: false

- name: Run agenta variant serve with overwrite
env:
BACKEND_HOST: ${{ secrets.BACKEND_HOST }}
run: |
cd agenta-cli
source $(poetry env info --path)/bin/activate
cd ../examples/baby_name_generator
poetry run agenta variant serve --file_name app.py --overwrite
cd examples/baby_name_generator
agenta variant serve --file_name app.py --overwrite
shell: bash
continue-on-error: false

# - name: Create .env file
# run: |
# echo "OPEN_API_KEY=${{ secrets.OPEN_API_KEY }}" > .env
# working-directory: examples/baby_name_generator

0 comments on commit 4edf551

Please sign in to comment.