@@ -75,42 +75,35 @@ jobs:
7575 - uses : ./.github/actions/setup-python
7676 - uses : ./.github/actions/setup-pyenv
7777 - uses : ./.github/actions/setup-java
78- - uses : ./.github/actions/cache-pip
7978 - name : Install dependencies
8079 run : |
81- python -m venv .venv
82- source .venv/bin/activate
83- source ./dev/install-common-deps.sh --ml
84- # transformers doesn't support Keras 3 yet. tf-keras needs to be installed as a workaround.
85- pip install tf-keras
86- # Pin numpy<2 for pmdarima compatibility (https://github.com/alkaline-ml/pmdarima/issues/577)
87- pip install "numpy<2"
88- # Ensure `databricks-connect` and `databricks-agents` are not installed
89- pip uninstall -y databricks-connect databricks-agents
90- pip install --no-deps --force-reinstall pyspark
80+ uv sync --extra extras --extra gateway --extra mcp
81+ uv pip install \
82+ -r requirements/test-requirements.txt \
83+ -r requirements/extra-ml-requirements.txt
9184 - uses : ./.github/actions/show-versions
9285 - uses : ./.github/actions/pipdeptree
9386 - name : Import check
9487 run : |
95- source .venv/bin/activate
9688 # `-I` is used to avoid importing modules from user-specific site-packages
9789 # that might conflict with the built-in modules (e.g. `types`).
98- python -I tests/check_mlflow_lazily_imports_ml_packages.py
90+ uv run --no-sync python -I tests/check_mlflow_lazily_imports_ml_packages.py
9991 - name : Run tests
10092 run : |
101- source .venv/bin/activate
10293 source dev/setup-ssh.sh
103- pytest --splits=${{ matrix.splits }} --group=${{ matrix.group }} --quiet --requires-ssh \
104- --ignore-flavors --ignore=tests/examples --ignore=tests/evaluate \
105- --ignore tests/genai tests
94+ uv run --no-sync pytest --splits=${{ matrix.splits }} --group=${{ matrix.group }} \
95+ --quiet --requires-ssh --ignore-flavors \
96+ --ignore=tests/examples \
97+ --ignore=tests/evaluate \
98+ --ignore=tests/genai \
99+ tests
106100
107101 - name : Run databricks-connect related tests
108102 run : |
109103 # this needs to be run in a separate job because installing databricks-connect could break other
110104 # tests that uses normal SparkSession instead of remote SparkSession
111- source .venv/bin/activate
112- pip install databricks-agents
113- pytest tests/utils/test_requirements_utils.py::test_infer_pip_requirements_on_databricks_agents
105+ uv run --no-sync --with databricks-agents \
106+ pytest tests/utils/test_requirements_utils.py::test_infer_pip_requirements_on_databricks_agents
114107
115108 database :
116109 if : github.event_name != 'pull_request' || github.event.pull_request.draft == false
@@ -124,7 +117,7 @@ jobs:
124117 - name : Build
125118 run : |
126119 ./tests/db/compose.sh pull -q postgresql mysql mssql
127- docker images
120+ docker images --digests
128121 ./tests/db/compose.sh build --build-arg DEPENDENCIES="$(python dev/extract_deps.py)"
129122 - name : Run tests
130123 run : |
0 commit comments