GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — `feast apply` silently ignores ttl updates when the new ttl is `None` or `timedelta(0)` · Issue #6703 · feast-dev/feast Closed Labels DescriptionExpected BehaviorRe-applying an existing Current BehaviorThe old ttl is silently retained.
if ( hasattr(existing_proto.spec, "ttl") and hasattr(updated_fv, "ttl") and updated_fv.ttl # falsy for both None and timedelta(0) ): Since Practical impact: a Steps to reproducefrom datetime import timedelta from feast import Entity, FeatureView, Field, FileSource, Project from feast.types import Float32 project = Project(name="ttl_repro") entity = Entity(name="foo", join_keys=["foo_id"]) source = FileSource( name="foo_source", path="./data/foo.parquet", timestamp_field="event_timestamp", ) # 1. Apply with a finite ttl -> fv.ttl == 10 days (correct) fv = FeatureView( name="foo_fv", entities=[entity], ttl=timedelta(days=10), schema=[Field(name="bar", dtype=Float32)], source=source, ) # 2. Change ttl to "no expiry" and `feast apply` again fv_v2 = FeatureView( name="foo_fv", entities=[entity], ttl=None, # or timedelta(days=0) - same result schema=[Field(name="bar", dtype=Float32)], source=source, ) Then check Specifications
Possible SolutionDrop the outer truthiness check and always sync ttl on update, relying on if hasattr(existing_proto.spec, "ttl") and hasattr(updated_fv, "ttl"): if isinstance(updated_fv, FeatureView): existing_proto.spec.ttl.CopyFrom(updated_fv.get_ttl_duration() or Duration()) elif isinstance(updated_fv, LabelView): ttl_duration = Duration() if updated_fv.ttl is not None: ttl_duration.FromTimedelta(updated_fv.ttl) existing_proto.spec.ttl.CopyFrom(ttl_duration) Happy to open a PR with this plus a regression test (apply with finite ttl, re-apply with Activity
MetadataMetadataAssigneesLabelsTypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |