diff --git a/fennel/CHANGELOG.md b/fennel/CHANGELOG.md index 967c49784..fb9d98524 100644 --- a/fennel/CHANGELOG.md +++ b/fennel/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog +## [1.5.8] - 2024-08-23 +- Fix selection of indexes from dataset decorator + ## [1.5.7] - 2024-08-21 - Fix proto for lookback diff --git a/fennel/datasets/datasets.py b/fennel/datasets/datasets.py index 4140c2efe..0d88a92d9 100644 --- a/fennel/datasets/datasets.py +++ b/fennel/datasets/datasets.py @@ -1198,17 +1198,32 @@ def dataset( raise ValueError( "When 'index' is set as True then 'offline' or 'online' params can only be set as False." ) - elif not offline and not online: + # handling @dataset(index=True) choosing both index + elif offline is None and online is None: index_obj = Index( type=IndexType.primary, online=True, offline=IndexDuration.forever, ) - elif not offline: + # handling @dataset(index=True, offline=False, online=False) choosing none + elif ( + not offline + and not online + and offline is not None + and online is not None + ): + index_obj = Index( + type=IndexType.primary, + online=False, + offline=IndexDuration.none, + ) + # handling @dataset(index=True, offline=False) choosing only offline index + elif offline is not None and not offline: index_obj = Index( type=IndexType.primary, online=True, offline=IndexDuration.none ) - else: + # handling @dataset(index=True, online=False) choosing only online index + elif online is not None and not online: index_obj = Index( type=IndexType.primary, online=False, diff --git a/pyproject.toml b/pyproject.toml index c0ae80419..58aa0408e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "fennel-ai" -version = "1.5.7" +version = "1.5.8" description = "The modern realtime feature engineering platform" authors = ["Fennel AI "] packages = [{ include = "fennel" }]