Title: feat: Add LanceFormat table format with version/tag pinning by haoxu0 · Pull Request #6925 · feast-dev/feast · GitHub
Open Graph Title: feat: Add LanceFormat table format with version/tag pinning by haoxu0 · Pull Request #6925 · feast-dev/feast
X Title: feat: Add LanceFormat table format with version/tag pinning by haoxu0 · Pull Request #6925 · feast-dev/feast
Description: Adds Lance to the existing TableFormat abstraction from #5650, rather than introducing a separate data source. Addresses the core of #6899. Why TableFormat and not a new source TableFormat already models Iceberg, Delta and Hudi as formats a source can carry, with catalog/namespace addressing and a properties bag. Lance fits that shape exactly, so it needs no new source class, no new offline store, and no changes to any existing consumer. LanceFormat( catalog="my_catalog", namespace="my_namespace", version=3, # or tag="candidate" ) It works with SparkSource unchanged SparkSource already drives its reader generically: reader = spark_session.read.format(self.table_format.format_type.value) for key, value in self.table_format.properties.items(): reader = reader.option(key, value) So mirroring the pin into properties is what makes this fall out for free. Verified: SparkSource accepted it : LanceFormat spark .format(...) value : lance reader .option(...) pairs : lance.catalog = polaris_dev lance.namespace = ml_features lance.version = 3 SparkSource proto rt : LanceFormat version = 3 Pin semantics version / tag is the Lance-shaped instance of #5782. Two invariants: version >= 1 is enforced. Lance dataset versions start at 1 and the proto treats 0 as unset, so without the guard version=0 would not round-trip — to_proto/from_proto read 0 as absent. Rejecting it keeps the Python and proto semantics in agreement rather than silently dropping a pin. version and tag are mutually exclusive, since a tag already resolves to a version. On the broader question @jfw-ppi raised in #5782 — whether a pin can change the response shape — the position I'd argue for is that a pin selects data, never shape: the declared FeatureView schema stays the contract, and a pinned version whose schema disagrees should fail explicitly. That belongs in whatever consumes the pin, so it is not in this PR, but the format carries enough information to enforce it. Proto regeneration, deliberately constrained Two things worth flagging, both about not doing the obvious thing. 1. Generated with grpcio-tools==1.62.3, not the pinned 1.84.0. Regenerating with the pinned toolchain emits gencode that opens with: _runtime_version.ValidateProtobufRuntimeVersion(_runtime_version.Domain.PUBLIC, 7, 35, 1, ...) pyproject.toml declares protobuf>=4.24.0. That call would hard-fail for anyone on protobuf 4/5/6 — and google.protobuf.runtime_version does not exist in 4.x at all, so it is an ImportError on that one module while every other proto still imports. Using 1.62.3 emits 4.25.1-level gencode, matching every other checked-in proto, and keeps the declared floor honest. Worth noting independently: the checked-in protos are at gencode 4.25.1 while the requirements pin grpcio-tools==1.84.0 / protobuf==7.36.2, so a full regeneration on master today would touch ~70 files and raise the effective protobuf floor. That looks like something to decide on purpose rather than as a side effect of a feature PR. 2. DataSource_pb2 is left untouched on purpose. Regenerating also rewrites DataSource_pb2.py/.pyi (~125 lines), but that churn is pre-existing — I verified it reproduces on pristine master with no changes at all. The checked-in copy is missing _CONNECTIONREF_PARAMSENTRY entries, i.e. it is stale against DataSource.proto. Happy to fix that separately; it does not belong here. Net result is 5 files, and only DataFormat_pb2 regenerated. Scope This adds the format descriptor. It does not add a Lance reader or offline store — that is the follow-on discussed in #6899, and it is why the tests here cover LanceFormat semantics rather than reading real datasets (no new test dependency on pylance). Also explicitly not proposing Lance as an online store: it is a format plus indexes, not a low-latency KV service, and its write path is columnar while online_write_batch is row-oriented proto. Testing 11 new tests in test_table_format.py (24 total in the file): creation, minimal construction, version pin, tag pin, version < 1 rejection, version+tag rejection, dict/json/proto round-trips, unpinned not coming back as version 0, and factory dispatch. test_table_format.py — 24 passed test_utils.py, test_data_sources.py, test_types.py — 52 passed, 1 skipped mypy feast/table_format.py — clean, no issues ruff check / ruff format --check — clean Related: #6899, #5782, #5650, #6499
Open Graph Description: Adds Lance to the existing TableFormat abstraction from #5650, rather than introducing a separate data source. Addresses the core of #6899. Why TableFormat and not a new source TableFormat already ...
X Description: Adds Lance to the existing TableFormat abstraction from #5650, rather than introducing a separate data source. Addresses the core of #6899. Why TableFormat and not a new source TableFormat already ...
Opengraph URL: https://github.com/feast-dev/feast/pull/6925
X: @github
Domain: github.com
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:eb5dbe76-0374-0df7-5057-40198019b652 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | C1A8:A7C31:EC71FC:137682F:6AFE98B2 |
| html-safe-nonce | 9785b5d317272b9223c99046c3328194dad2b5e2f9c14f2ce234ee22c09b2f59 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDMUE4OkE3QzMxOkVDNzFGQzoxMzc2ODJGOjZBRkU5OEIyIiwidmlzaXRvcl9pZCI6IjI2NjYyMDAyODA0OTU3MjQ3MjIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | bb8b9f50e1f5bb8133172f7738c9895f1d9b35f8fbb8956578777d0fb9330ceb |
| hovercard-subject-tag | pull_request:4709193530 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/feast-dev/feast/pull/6925/files |
| twitter:image | https://avatars.githubusercontent.com/u/20422210?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/20422210?s=400&v=4 |
| og:image:alt | Adds Lance to the existing TableFormat abstraction from #5650, rather than introducing a separate data source. Addresses the core of #6899. Why TableFormat and not a new source TableFormat already ... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | b3c0f155eafc27e60db6e254d1ffff0e072e9ab3b4018a5ee518797c19d89f86 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/feast-dev/feast git https://github.com/feast-dev/feast.git |
| octolytics-dimension-user_id | 57027613 |
| octolytics-dimension-user_login | feast-dev |
| octolytics-dimension-repository_id | 161133770 |
| octolytics-dimension-repository_nwo | feast-dev/feast |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 161133770 |
| octolytics-dimension-repository_network_root_nwo | feast-dev/feast |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 4a10310af51a1bfffbedc4fd81cb582acf0cb0ff |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width