* Update database file path handling in base.py and version.py * Update server.py to handle SIGINT signal in LangflowUvicornWorker * Add shutdown message when shutting down Langflow in main.py * Update datetime type for created_at and updated_at fields in apikey and variable tables * Update package versions in pyproject.toml and poetry.lock files * Update package versions in pyproject.toml and poetry.lock files * Fix import error in base.py * Refactor database file path handling in base.py * Update unit test command in python_test.yml
44 lines
1.1 KiB
YAML
44 lines
1.1 KiB
YAML
name: test
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- "poetry.lock"
|
|
- "pyproject.toml"
|
|
- "src/backend/**"
|
|
pull_request:
|
|
branches: [dev]
|
|
paths:
|
|
- "poetry.lock"
|
|
- "pyproject.toml"
|
|
- "src/backend/**"
|
|
|
|
env:
|
|
POETRY_VERSION: "1.8.2"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
python-version:
|
|
- "3.10"
|
|
- "3.11"
|
|
env:
|
|
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Set up Python ${{ matrix.python-version }} + Poetry ${{ env.POETRY_VERSION }}
|
|
uses: "./.github/actions/poetry_caching"
|
|
with:
|
|
python-version: ${{ matrix.python-version }}
|
|
poetry-version: ${{ env.POETRY_VERSION }}
|
|
cache-key: ${{ runner.os }}-poetry-${{ env.POETRY_VERSION }}-${{ hashFiles('**/poetry.lock') }}
|
|
- name: Install Python dependencies
|
|
run: |
|
|
poetry env use ${{ matrix.python-version }}
|
|
poetry install
|
|
- name: Run unit tests
|
|
run: |
|
|
make tests args="-n auto"
|