Title: NotImplementedError raised when using FeatureStore.push() · Issue #4403 · feast-dev/feast · GitHub
Open Graph Title: NotImplementedError raised when using FeatureStore.push() · Issue #4403 · feast-dev/feast
X Title: NotImplementedError raised when using FeatureStore.push() · Issue #4403 · feast-dev/feast
Description: Expected Behavior I'm currently starting to try simple usecase of Feast v0.40 for local development, I'm ingesting data from Airflow job to Postgres. def process(): ... store = FeatureStore(repo_path=f"{mother_path}/helpers/feast/") driv...
Open Graph Description: Expected Behavior I'm currently starting to try simple usecase of Feast v0.40 for local development, I'm ingesting data from Airflow job to Postgres. def process(): ... store = FeatureStore(repo_pa...
X Description: Expected Behavior I'm currently starting to try simple usecase of Feast v0.40 for local development, I'm ingesting data from Airflow job to Postgres. def process(): ... store = FeatureStore...
Opengraph URL: https://github.com/feast-dev/feast/issues/4403
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"NotImplementedError raised when using FeatureStore.push()","articleBody":"## Expected Behavior \r\nI'm currently starting to try simple usecase of Feast v0.40 for local development, I'm ingesting data from Airflow job to Postgres.\r\n```\r\ndef process():\r\n ...\r\n store = FeatureStore(repo_path=f\"{mother_path}/helpers/feast/\")\r\n\r\n driver = Entity(name=\"driver_id\", join_keys=[\"driver_id\"], description=\"driver ID\")\r\n\r\n table_name = 'feast_driver_hourly_stats'\r\n create_postgres_table(\r\n table_name=table_name, \r\n schema=\"\"\"\r\n driver_id SERIAL PRIMARY KEY,\r\n event_timestamp TIMESTAMP,\r\n surge_score FLOAT,\r\n trip_cancel INT,\r\n number_trip INT,\r\n latest_completed INT\r\n \"\"\"\r\n )\r\n \r\n\r\n driver_stats_source = PostgreSQLSource(\r\n name=table_name,\r\n query=f\"SELECT * FROM airflow.feast.{table_name}\",\r\n timestamp_field=\"event_timestamp\",\r\n )\r\n\r\n push_source = PushSource(\r\n name=\"push_source\",\r\n batch_source=driver_stats_source\r\n )\r\n\r\n # Define the feature view (without specifying a source since we'll use a DataFrame)\r\n driver_feature_view = FeatureView(\r\n name=\"driver_feature_view\",\r\n entities=[driver],\r\n ttl=None, # Set TTL if needed\r\n schema=[\r\n Field(name=\"surge_score\", dtype=Float32),\r\n Field(name=\"trip_cancel\", dtype=Int64),\r\n Field(name=\"number_trip\", dtype=Int64),\r\n Field(name=\"latest_completed\", dtype=Int64),\r\n ],\r\n # online=True,\r\n stream_source=push_source\r\n )\r\n\r\n # Apply the feature store (register entities and feature views)\r\n store.apply([driver_feature_view])\r\n result = store.push(\"push_source\", data, to=PushMode.OFFLINE)\r\n```\r\nI have ensured that the database, the schema, and the table exists. I expect after calling push(), the data will then be ingested (written) into the destined table.\r\n\r\n## Current Behavior\r\nSuddenly, I got the follow error:\r\n```\r\nFile \"/opt/airflow/dags/test_feast.py\", line 112, in process\r\n result = store.push(\"push_source\", data, to=PushMode.OFFLINE)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/airflow/.local/lib/python3.11/site-packages/feast/feature_store.py\", line 1427, in push\r\n self.write_to_offline_store(\r\n File \"/home/airflow/.local/lib/python3.11/site-packages/feast/feature_store.py\", line 1511, in write_to_offline_store\r\n provider.ingest_df_to_offline_store(feature_view, table)\r\n File \"/home/airflow/.local/lib/python3.11/site-packages/feast/infra/passthrough_provider.py\", line 303, in ingest_df_to_offline_store\r\n self.offline_write_batch(self.repo_config, feature_view, table, None)\r\n File \"/home/airflow/.local/lib/python3.11/site-packages/feast/infra/passthrough_provider.py\", line 180, in offline_write_batch\r\n self.offline_store.__class__.offline_write_batch(\r\n File \"/home/airflow/.local/lib/python3.11/site-packages/feast/infra/offline_stores/offline_store.py\", line 353, in offline_write_batch\r\n raise NotImplementedError\r\n```\r\nThe `write_to_offline_store()` method might have called directly to an interface, causing the bug. I'm currently trying to review my configs/codes to spot any mistake and also read the `push()` method. However, I think I might have to raise an issue here.\r\n\r\n### Specifications\r\n\r\n- Version: v0.40\r\n- Platform: Airflow, Postgres\r\n- Subsystem: Python 3.11\r\n","author":{"url":"https://github.com/singsinghai","@type":"Person","name":"singsinghai"},"datePublished":"2024-08-13T10:52:02.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":4},"url":"https://github.com/4403/feast/issues/4403"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:c3cc5d00-102b-ff41-f617-016041719e14 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C980:CD74F:3B71081:5482763:6A56B3B6 |
| html-safe-nonce | c2cdc0780c568822222f824a4aa163651b46f010ffde5a7fb0192a9303f2f400 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDOTgwOkNENzRGOjNCNzEwODE6NTQ4Mjc2Mzo2QTU2QjNCNiIsInZpc2l0b3JfaWQiOiI0ODEzNjA5MjAwMzQ4NzM4NDg2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 4da32678d3395106778d061bdea29e977b876ab8f2fa7200bbfede94277d682b |
| hovercard-subject-tag | issue:2463039576 |
| github-keyboard-shortcuts | repository,issues,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/_view_fragments/issues/show/feast-dev/feast/4403/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f25b260a9c428bdebfa9b65d8857ab9add93ab82a470efebd8d37938fd63c05d/feast-dev/feast/issues/4403 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f25b260a9c428bdebfa9b65d8857ab9add93ab82a470efebd8d37938fd63c05d/feast-dev/feast/issues/4403 |
| og:image:alt | Expected Behavior I'm currently starting to try simple usecase of Feast v0.40 for local development, I'm ingesting data from Airflow job to Postgres. def process(): ... store = FeatureStore(repo_pa... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | singsinghai |
| hostname | github.com |
| expected-hostname | github.com |
| None | df99b7164e1d961b639cf5d3cbd6b5ba673edc67bd7e47cdc4746b96099e11ae |
| turbo-cache-control | no-preview |
| 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 |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | c29ba03b1896083dbe1084f6cd1c5367d8a0d67c |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width