Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into remote_offline
Browse files Browse the repository at this point in the history
  • Loading branch information
dmartinol committed May 22, 2024
2 parents aa9bcbd + 2b398dc commit d901ac2
Show file tree
Hide file tree
Showing 72 changed files with 203 additions and 1,217 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,10 @@ lock-python-dependencies-all:
pixi run --environment py311 --manifest-path infra/scripts/pixi/pixi.toml "uv pip compile --system --no-strip-extras setup.py --extra ci --output-file sdk/python/requirements/py3.11-ci-requirements.txt"

benchmark-python:
FEAST_USAGE=False IS_TEST=True python -m pytest --integration --benchmark --benchmark-autosave --benchmark-save-data sdk/python/tests
IS_TEST=True python -m pytest --integration --benchmark --benchmark-autosave --benchmark-save-data sdk/python/tests

benchmark-python-local:
FEAST_USAGE=False IS_TEST=True FEAST_IS_LOCAL_TEST=True python -m pytest --integration --benchmark --benchmark-autosave --benchmark-save-data sdk/python/tests
IS_TEST=True FEAST_IS_LOCAL_TEST=True python -m pytest --integration --benchmark --benchmark-autosave --benchmark-save-data sdk/python/tests

test-python-unit:
python -m pytest -n 8 --color=yes sdk/python/tests
Expand Down Expand Up @@ -372,7 +372,7 @@ start-trino-locally:
sleep 15

test-trino-plugin-locally:
cd ${ROOT_DIR}/sdk/python; FULL_REPO_CONFIGS_MODULE=feast.infra.offline_stores.contrib.trino_offline_store.test_config.manual_tests FEAST_USAGE=False IS_TEST=True python -m pytest --integration tests/
cd ${ROOT_DIR}/sdk/python; FULL_REPO_CONFIGS_MODULE=feast.infra.offline_stores.contrib.trino_offline_store.test_config.manual_tests IS_TEST=True python -m pytest --integration tests/

kill-trino-locally:
cd ${ROOT_DIR}; docker stop trino
Expand Down
4 changes: 0 additions & 4 deletions docs/how-to-guides/adding-or-reusing-tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ $ tree
│ ├── test_go_feature_server.py
│ ├── test_python_feature_server.py
│ ├── test_universal_e2e.py
│ ├── test_usage_e2e.py
│ └── test_validation.py
├── feature_repos
│ ├── integration_test_repo_config.py
Expand Down Expand Up @@ -99,8 +98,6 @@ If a test can be run purely locally (where locally includes Docker resources), i
* `test_go_feature_server.py`
* python http server
* `test_python_feature_server.py`
* usage tracking
* `test_usage_e2e.py`
* data quality monitoring feature validation
* `test_validation.py`
2. Offline and Online Store Tests
Expand Down Expand Up @@ -149,7 +146,6 @@ If a test can be run purely locally (where locally includes Docker resources), i
* Type mapping
* Feast types
* Serialization tests due to this [issue](https://github.com/feast-dev/feast/issues/2345)
* Feast usage tracking unit tests

#### Docstring tests

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ test-python-universal-spark:
PYTHONPATH='.' \
FULL_REPO_CONFIGS_MODULE=sdk.python.feast.infra.offline_stores.contrib.spark_repo_configuration \
PYTEST_PLUGINS=feast.infra.offline_stores.contrib.spark_offline_store.tests \
FEAST_USAGE=False IS_TEST=True \
IS_TEST=True \
python -m pytest -n 8 --integration \
-k "not test_historical_retrieval_fails_on_validation and \
not test_historical_retrieval_with_validation and \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,6 @@ test-python-universal-cassandra:
PYTHONPATH='.' \
FULL_REPO_CONFIGS_MODULE=sdk.python.feast.infra.online_stores.contrib.cassandra_repo_configuration \
PYTEST_PLUGINS=sdk.python.tests.integration.feature_repos.universal.online_store.cassandra \
FEAST_USAGE=False \
IS_TEST=True \
python -m pytest -x --integration \
sdk/python/tests
Expand Down
12 changes: 0 additions & 12 deletions docs/reference/usage.md

This file was deleted.

1 change: 0 additions & 1 deletion infra/scripts/test-end-to-end.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,5 @@ make build-java-no-tests REVISION=develop
python -m pip install --upgrade pip setuptools wheel pip-tools
make install-python
python -m pip install -qr tests/requirements.txt
export FEAST_USAGE="False"

su -p postgres -c "PATH=$PATH HOME=/tmp pytest -v tests/e2e/ --feast-version develop"
8 changes: 0 additions & 8 deletions sdk/python/docs/source/feast.rst
Original file line number Diff line number Diff line change
Expand Up @@ -321,14 +321,6 @@ feast.ui\_server module
:undoc-members:
:show-inheritance:

feast.usage module
------------------

.. automodule:: feast.usage
:members:
:undoc-members:
:show-inheritance:

feast.utils module
------------------

Expand Down
4 changes: 2 additions & 2 deletions sdk/python/feast/batch_feature_view.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import warnings
from datetime import datetime, timedelta
from typing import Dict, List, Optional, Tuple, Union
from typing import Dict, List, Optional, Tuple

from feast import flags_helper
from feast.data_source import DataSource
Expand Down Expand Up @@ -60,7 +60,7 @@ def __init__(
*,
name: str,
source: DataSource,
entities: Optional[Union[List[Entity], List[str]]] = None,
entities: Optional[List[Entity]] = None,
ttl: Optional[timedelta] = None,
tags: Optional[Dict[str, str]] = None,
online: bool = True,
Expand Down
10 changes: 5 additions & 5 deletions sdk/python/feast/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ def ui(
host: str,
port: int,
registry_ttl_sec: int,
root_path: Optional[str] = "",
root_path: str = "",
):
"""
Shows the Feast UI over the current directory
Expand Down Expand Up @@ -836,12 +836,12 @@ def validate(
"""
store = create_feature_store(ctx)

feature_service = store.get_feature_service(name=feature_service)
reference = store.get_validation_reference(reference)
_feature_service = store.get_feature_service(name=feature_service)
_reference = store.get_validation_reference(reference)

result = store.validate_logged_features(
source=feature_service,
reference=reference,
source=_feature_service,
reference=_reference,
start=maybe_local_tz(datetime.fromisoformat(start_ts)),
end=maybe_local_tz(datetime.fromisoformat(end_ts)),
throw_exception=False,
Expand Down
6 changes: 0 additions & 6 deletions sdk/python/feast/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,6 @@
# Environment variable for registry
REGISTRY_ENV_NAME: str = "REGISTRY_BASE64"

# Environment variable for toggling the Usage feature
FEAST_USAGE = "FEAST_USAGE"

# Environment variable for FEAST_USAGE_ENDPOINT
FEAST_USAGE_ENDPOINT = "FEAST_USAGE_ENDPOINT"

# Environment variable for the path for overwriting universal test configs
FULL_REPO_CONFIGS_MODULE_ENV_NAME: str = "FULL_REPO_CONFIGS_MODULE"

Expand Down
2 changes: 1 addition & 1 deletion sdk/python/feast/embedded_go/online_features_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ def transformation_callback(
f"OnDemandFeatureView mode '{odfv.mode} not supported by EmbeddedOnlineFeatureServer."
)

output = odfv.get_transformed_features_df(
output = odfv.get_transformed_features_df( # type: ignore
input_record.to_pandas(), full_feature_names=full_feature_names
)
output_record = pa.RecordBatch.from_pandas(output)
Expand Down
2 changes: 0 additions & 2 deletions sdk/python/feast/entity.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
from feast.protos.feast.core.Entity_pb2 import Entity as EntityProto
from feast.protos.feast.core.Entity_pb2 import EntityMeta as EntityMetaProto
from feast.protos.feast.core.Entity_pb2 import EntitySpecV2 as EntitySpecProto
from feast.usage import log_exceptions
from feast.value_type import ValueType


Expand Down Expand Up @@ -52,7 +51,6 @@ class Entity:
created_timestamp: Optional[datetime]
last_updated_timestamp: Optional[datetime]

@log_exceptions
def __init__(
self,
*,
Expand Down
2 changes: 0 additions & 2 deletions sdk/python/feast/feature_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
from feast.protos.feast.core.FeatureService_pb2 import (
FeatureServiceSpec as FeatureServiceSpecProto,
)
from feast.usage import log_exceptions


@typechecked
Expand Down Expand Up @@ -50,7 +49,6 @@ class FeatureService:
last_updated_timestamp: Optional[datetime] = None
logging_config: Optional[LoggingConfig] = None

@log_exceptions
def __init__(
self,
*,
Expand Down
Loading

0 comments on commit d901ac2

Please sign in to comment.