Skip to content

Test requirements

Test requirements #644

Workflow file for this run

name: Test requirements
on:
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
paths:
- requirements/core-requirements.yaml
- requirements/skinny-requirements.yaml
- requirements/gateway-requirements.yaml
- .github/workflows/requirements.yml
schedule:
- cron: "0 13 * * *"
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: true
env:
MLFLOW_HOME: /home/runner/work/mlflow/mlflow
MLFLOW_CONDA_HOME: /usr/share/miniconda
SPARK_LOCAL_IP: localhost
PYTHON_VERSION: "3.10" # mininum supported version + 1
defaults:
run:
shell: bash --noprofile --norc -exo pipefail {0}
jobs:
skinny:
runs-on: ubuntu-latest
timeout-minutes: 10
permissions: {}
if: (github.event_name == 'schedule' && github.repository == 'mlflow-automation/mlflow') || (github.event_name == 'pull_request' && github.event.pull_request.draft == false)
steps:
- uses: actions/checkout@v4
with:
repository: ${{ github.event_name == 'schedule' && 'mlflow/mlflow' || null }}
submodules: recursive
- uses: ./.github/actions/setup-python
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Install dev script dependencies
run: |
pip install -r dev/requirements.txt
- uses: ./.github/actions/update-requirements
if: github.event_name == 'schedule'
- name: Install dependencies
run: |
source ./dev/install-common-deps.sh --skinny
- name: Run tests
run: |
./dev/run-python-skinny-tests.sh
core:
runs-on: ubuntu-latest
timeout-minutes: 120
permissions: {}
if: (github.event_name == 'schedule' && github.repository == 'mlflow-automation/mlflow') || (github.event_name == 'pull_request' && github.event.pull_request.draft == false)
steps:
- uses: actions/checkout@v4
with:
repository: ${{ github.event_name == 'schedule' && 'mlflow/mlflow' || null }}
submodules: recursive
- uses: ./.github/actions/free-disk-space
- uses: ./.github/actions/setup-python
with:
python-version: ${{ env.PYTHON_VERSION }}
- uses: ./.github/actions/setup-pyenv
- uses: ./.github/actions/setup-java
- name: Install dev script dependencies
run: |
pip install -r dev/requirements.txt
- uses: ./.github/actions/update-requirements
if: github.event_name == 'schedule'
- name: Install dependencies
run: |
source ./dev/install-common-deps.sh --ml
pip install '.[gateway]'
# transformers doesn't support Keras 3 yet. tf-keras needs to be installed as a workaround.
pip install tf-keras
- name: Run tests
run: |
source dev/setup-ssh.sh
pytest tests --quiet --requires-ssh --ignore-flavors \
--ignore=tests/examples --ignore=tests/recipes --ignore=tests/evaluate \
--ignore=tests/deployments