Skip to content

Update requirements.txt #8

Update requirements.txt

Update requirements.txt #8

Workflow file for this run

name: Python Tests
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
fail-fast: false # Continue with other versions if one fails
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y build-essential
- name: Install Ollama
run: |
curl -fsSL https://ollama.com/install.sh | sh
ollama serve &
sleep 15 # Give more time for Ollama to start
ollama pull llama3.2
ollama pull nomic-embed-text
continue-on-error: true # Don't fail if model pull has issues
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install pytest pytest-cov
pip install -r requirements.txt
- name: Run tests with coverage
run: |
pytest tests/ --cov=src --cov-report=html --cov-report=term
env:
PYTHONPATH: ${{ github.workspace }}
- name: Upload test results
if: always() # Upload even if tests fail
uses: actions/upload-artifact@v3
with:
name: test-results-${{ matrix.python-version }}
path: |
htmlcov
if-no-files-found: warn # Don't fail if no coverage files