Skip to content

Bump langchain-openai from 1.0.3 to 1.1.0 in /py-django-crewai #215

Bump langchain-openai from 1.0.3 to 1.1.0 in /py-django-crewai

Bump langchain-openai from 1.0.3 to 1.1.0 in /py-django-crewai #215

name: py-django-crewai CI/CD
on:
workflow_call:
workflow_dispatch:
push:
paths:
- 'py-django-crewai/**'
- '.github/workflows/py-django-crewai.yml'
pull_request:
paths:
- 'py-django-crewai/**'
- '.github/workflows/py-django-crewai.yml'
permissions:
contents: read
jobs:
backend-test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: py-django-crewai
steps:
- uses: actions/checkout@v5
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.12'
cache: 'pip'
- name: Install backend dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run backend tests
run: |
python manage.py test || echo "No tests run"
frontend-build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: py-django-crewai
steps:
- uses: actions/checkout@v5
- name: Set up Node.js
uses: actions/setup-node@v6
with:
node-version: '18'
- name: Install frontend dependencies
run: |
cd frontend
npm install
- name: Build frontend
run: |
./build_frontend.sh
- name: Set up Python for static collection
uses: actions/setup-python@v6
with:
python-version: '3.12'
cache: 'pip'
- name: Collect static files
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
python manage.py collectstatic --noinput || echo "Static collection skipped"
- name: Upload build artifacts
uses: actions/upload-artifact@v5
with:
name: frontend-build
path: |
py-django-crewai/frontend/dist
py-django-crewai/static
package:
needs: [backend-test, frontend-build]
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
defaults:
run:
working-directory: py-django-crewai
steps:
- uses: actions/checkout@v5
- name: Download frontend build
uses: actions/download-artifact@v6
with:
name: frontend-build
path: py-django-crewai
- name: Create package
run: |
mkdir -p dist
zip -r dist/py-django-crewai.zip . -x "*.git*" "*.env*" "*.pyc" "__pycache__/*" "*.github/*" "dist/*" "frontend/node_modules/*"
- name: Upload package artifact
uses: actions/upload-artifact@v5
with:
name: py-django-crewai-package
path: py-django-crewai/dist