@@ -55,12 +55,12 @@ protos: compile-protos-python compile-protos-docs ## Compile protobufs for Pytho
5555build : protos build-docker # # Build protobufs and Docker images
5656
5757format-python : # # Format Python code
58- cd $( ROOT_DIR ) && uv run ruff check --fix sdk/python/feast/ sdk/python/tests/
59- cd $( ROOT_DIR ) && uv run ruff format sdk/python/feast/ sdk/python/tests/
58+ uv run ruff check --fix sdk/python/feast/ sdk/python/tests/
59+ uv run ruff format sdk/python/feast/ sdk/python/tests/
6060
6161lint-python : # # Lint Python code
62- cd $( ROOT_DIR ) && uv run ruff check sdk/python/feast/ sdk/python/tests/
63- cd $( ROOT_DIR ) && uv run sh -c " cd sdk/python && mypy feast"
62+ uv run ruff check sdk/python/feast/ sdk/python/tests/
63+ uv run bash -c " cd sdk/python && mypy feast"
6464
6565# New combined target
6666precommit-check : format-python lint-python # # Run all precommit checks
@@ -74,7 +74,7 @@ install-precommit: ## Install precommit hooks (runs on commit, not push)
7474
7575# Manual full type check
7676mypy-full : # # Full MyPy type checking with all files
77- cd ${ROOT_DIR} && uv run sh -c " cd sdk/python && mypy feast tests"
77+ uv run bash -c " cd sdk/python && mypy feast tests"
7878
7979# Run precommit on all files
8080precommit-all : # # Run all precommit hooks on all files
@@ -95,21 +95,12 @@ install-python-dependencies-minimal: ## Install minimal Python dependencies usin
9595 uv pip sync --require-hashes sdk/python/requirements/py$(PYTHON_VERSION ) -minimal-requirements.txt
9696 uv pip install --no-deps -e .[minimal]
9797
98- # #@ Python SDK - system
99- # the --system flag installs dependencies in the global python context
100- # instead of a venv which is useful when working in a docker container or ci.
98+ # #@ Python SDK - CI (uses uv project management)
99+ # Uses uv sync for consistent behavior between local and CI environments
101100
102101# Used in github actions/ci
103- # formerly install-python-ci-dependencies-uv
104- install-python-dependencies-ci : # # Install Python CI dependencies using uv (system)
105- @if [ " $$ (uname -s)" = " Linux" ]; then \
106- echo " Installing dependencies with torch CPU index for Linux..." ; \
107- uv pip sync --system --extra-index-url https://download.pytorch.org/whl/cpu --index-strategy unsafe-best-match sdk/python/requirements/py$(PYTHON_VERSION ) -ci-requirements.txt; \
108- else \
109- echo " Installing dependencies from PyPI for macOS..." ; \
110- uv pip sync --system sdk/python/requirements/py$(PYTHON_VERSION ) -ci-requirements.txt; \
111- fi
112- uv pip install --system --no-deps -e .
102+ install-python-dependencies-ci : # # Install Python CI dependencies using uv sync
103+ uv sync --extra ci
113104
114105# Used in github actions/ci
115106install-hadoop-dependencies-ci : # # Install Hadoop dependencies
@@ -170,33 +161,33 @@ benchmark-python-local: ## Run integration + benchmark tests for Python (local d
170161# #@ Tests
171162
172163test-python-unit : # # Run Python unit tests (use pattern=<pattern> to filter tests, e.g., pattern=milvus, pattern=test_online_retrieval.py, pattern=test_online_retrieval.py::test_get_online_features_milvus)
173- cd $( ROOT_DIR ) && uv run python -m pytest -n 8 --color=yes $(if $(pattern ) ,-k "$(pattern ) ") sdk/python/tests
164+ uv run python -m pytest -n 8 --color=yes $(if $(pattern ) ,-k "$(pattern ) ") sdk/python/tests
174165
175166# Fast unit tests only
176167test-python-unit-fast : # # Run fast unit tests only (no external dependencies)
177- cd $( ROOT_DIR ) && uv run python -m pytest sdk/python/tests/unit -n auto -x --tb=short
168+ uv run python -m pytest sdk/python/tests/unit -n auto -x --tb=short
178169
179170# Changed files only (requires pytest-testmon)
180171test-python-changed : # # Run tests for changed files only
181- cd $( ROOT_DIR ) && uv run python -m pytest --testmon -n 8 --tb=short sdk/python/tests
172+ uv run python -m pytest --testmon -n 8 --tb=short sdk/python/tests
182173
183174# Quick smoke test for PRs
184175test-python-smoke : # # Quick smoke test for development
185- cd $( ROOT_DIR ) && uv run python -m pytest \
176+ uv run python -m pytest \
186177 sdk/python/tests/unit/test_unit_feature_store.py \
187178 sdk/python/tests/unit/test_repo_operations_validate_feast_project_name.py \
188179 -n 4 --tb=short
189180
190181test-python-integration : # # Run Python integration tests (CI)
191- cd $( ROOT_DIR ) && uv run python -m pytest --tb=short -v -n 8 --integration --color=yes --durations=10 --timeout=1200 --timeout_method=thread --dist loadgroup \
182+ uv run python -m pytest --tb=short -v -n 8 --integration --color=yes --durations=10 --timeout=1200 --timeout_method=thread --dist loadgroup \
192183 -k " (not snowflake or not test_historical_features_main)" \
193184 -m " not rbac_remote_integration_test" \
194185 --log-cli-level=INFO -s \
195186 sdk/python/tests
196187
197188# Integration tests with better parallelization
198189test-python-integration-parallel : # # Run integration tests with enhanced parallelization
199- cd $( ROOT_DIR ) && uv run python -m pytest sdk/python/tests/integration \
190+ uv run python -m pytest sdk/python/tests/integration \
200191 -n auto --dist loadscope \
201192 --timeout=300 --tb=short -v \
202193 --integration --color=yes --durations=20
@@ -207,7 +198,7 @@ test-python-integration-local: ## Run Python integration tests (local dev mode)
207198 HADOOP_HOME=$$ HOME/hadoop \
208199 CLASSPATH=" $$ ( $$ HADOOP_HOME/bin/hadoop classpath --glob ):$$ CLASSPATH" \
209200 HADOOP_USER_NAME=root \
210- cd $( ROOT_DIR ) && uv run python -m pytest --tb=short -v -n 8 --color=yes --integration --durations=10 --timeout=1200 --timeout_method=thread --dist loadgroup \
201+ uv run python -m pytest --tb=short -v -n 8 --color=yes --integration --durations=10 --timeout=1200 --timeout_method=thread --dist loadgroup \
211202 -k " not test_lambda_materialization and not test_snowflake_materialization" \
212203 -m " not rbac_remote_integration_test" \
213204 --log-cli-level=INFO -s \
@@ -216,7 +207,7 @@ test-python-integration-local: ## Run Python integration tests (local dev mode)
216207test-python-integration-rbac-remote : # # Run Python remote RBAC integration tests
217208 FEAST_IS_LOCAL_TEST=True \
218209 FEAST_LOCAL_ONLINE_CONTAINER=True \
219- cd $( ROOT_DIR ) && uv run python -m pytest --tb=short -v -n 8 --color=yes --integration --durations=10 --timeout=1200 --timeout_method=thread --dist loadgroup \
210+ uv run python -m pytest --tb=short -v -n 8 --color=yes --integration --durations=10 --timeout=1200 --timeout_method=thread --dist loadgroup \
220211 -k " not test_lambda_materialization and not test_snowflake_materialization" \
221212 -m " rbac_remote_integration_test" \
222213 --log-cli-level=INFO -s \
@@ -225,7 +216,7 @@ test-python-integration-rbac-remote: ## Run Python remote RBAC integration tests
225216test-python-integration-container : # # Run Python integration tests using Docker
226217 @ (docker info > /dev/null 2>&1 && \
227218 FEAST_LOCAL_ONLINE_CONTAINER=True \
228- cd $( ROOT_DIR ) && uv run python -m pytest -n 8 --integration sdk/python/tests \
219+ uv run python -m pytest -n 8 --integration sdk/python/tests \
229220 ) || echo " This script uses Docker, and it isn't running - please start the Docker Daemon and try again!" ;
230221
231222test-python-universal-spark : # # Run Python Spark integration tests
@@ -597,7 +588,7 @@ test-python-universal-couchbase-online: ## Run Python Couchbase online store int
597588 sdk/python/tests
598589
599590test-python-universal : # # Run all Python integration tests
600- cd $( ROOT_DIR ) && uv run python -m pytest -n 8 --integration sdk/python/tests
591+ uv run python -m pytest -n 8 --integration sdk/python/tests
601592
602593# #@ Java
603594
0 commit comments