Title: Feast BigQuery offline store gets wrong argument types for `event_timestamp` · Issue #2532 · feast-dev/feast · GitHub
Open Graph Title: Feast BigQuery offline store gets wrong argument types for `event_timestamp` · Issue #2532 · feast-dev/feast
X Title: Feast BigQuery offline store gets wrong argument types for `event_timestamp` · Issue #2532 · feast-dev/feast
Description: Expected Behavior Retrieving training data from an offline store that is BigQuery by using get_historical_features method from Python SDK. Current Behavior Getting this error when running get_historical_features: Traceback (most recent c...
Open Graph Description: Expected Behavior Retrieving training data from an offline store that is BigQuery by using get_historical_features method from Python SDK. Current Behavior Getting this error when running get_histo...
X Description: Expected Behavior Retrieving training data from an offline store that is BigQuery by using get_historical_features method from Python SDK. Current Behavior Getting this error when running get_histo...
Opengraph URL: https://github.com/feast-dev/feast/issues/2532
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Feast BigQuery offline store gets wrong argument types for `event_timestamp`","articleBody":"## Expected Behavior \r\nRetrieving training data from an offline store that is BigQuery by using `get_historical_features` method from Python SDK.\r\n\r\n## Current Behavior\r\nGetting this error when running `get_historical_features`:\r\n\r\n```sh\r\nTraceback (most recent call last):\r\n File \"get_offline_data.py\", line 22, in \u003cmodule\u003e\r\n \"item_user_stats_v1:is_high_risk_seller\",\r\n File \"/usr/local/lib/python3.7/site-packages/feast/infra/offline_stores/offline_store.py\", line 77, in to_df\r\n features_df = self._to_df_internal()\r\n File \"/usr/local/lib/python3.7/site-packages/feast/infra/offline_stores/bigquery.py\", line 290, in _to_df_internal\r\n df = self._execute_query(query).to_dataframe(create_bqstorage_client=True)\r\n File \"/usr/local/lib/python3.7/site-packages/feast/usage.py\", line 280, in wrapper\r\n raise exc.with_traceback(traceback)\r\n File \"/usr/local/lib/python3.7/site-packages/feast/usage.py\", line 269, in wrapper\r\n return func(*args, **kwargs)\r\n File \"/usr/local/lib/python3.7/site-packages/feast/infra/offline_stores/bigquery.py\", line 357, in _execute_query\r\n block_until_done(client=self.client, bq_job=bq_job, timeout=timeout)\r\n File \"/usr/local/lib/python3.7/site-packages/feast/infra/offline_stores/bigquery.py\", line 415, in block_until_done\r\n raise bq_job.exception()\r\ngoogle.api_core.exceptions.BadRequest: 400 No matching signature for operator \u003c= for argument types: TIMESTAMP, DATETIME. Supported signature: ANY \u003c= ANY at [78:13]\r\n``` \r\nThe error happens on a query where it compares event timestamps (last line):\r\n ```SQL\r\n item_user_stats_v1__base AS (\r\n SELECT\r\n subquery.*,\r\n entity_dataframe.entity_timestamp,\r\n entity_dataframe.item_user_stats_v1__entity_row_unique_id\r\n FROM item_user_stats_v1__subquery AS subquery\r\n INNER JOIN item_user_stats_v1__entity_dataframe AS entity_dataframe\r\n ON TRUE\r\n AND subquery.event_timestamp \u003c= entity_dataframe.entity_timestamp\r\n```\r\n \r\n## Steps to reproduce\r\nUse Feast project with GCP provider, where the offline store is BigQuery. After installing feast[gcp] (v0.19.4) packages you should get this `google-cloud-bigquery==3.0.1` dependency version. I think it should brake also with newer versions of `google-cloud-bigquery` if it will be available.\r\n\r\n\r\n### Specifications\r\n\r\n- Version: v0.19.4\r\n- Platform: GCP\r\n- Subsystem:\r\n\r\n## Possible Solution\r\nQuick solution: add upper bound of `\u003c3.0.0` [here](https://github.com/feast-dev/feast/blob/fc3498109477585272b441e094a267fc1b9a5d04/sdk/python/setup.py#L74).\r\n\r\nA better solution: check what is causing this event timestamp type mismatch and fix it 😊 . ","author":{"url":"https://github.com/KarolisKont","@type":"Person","name":"KarolisKont"},"datePublished":"2022-04-13T13:43:47.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":5},"url":"https://github.com/2532/feast/issues/2532"}
| 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:5ca487a8-6827-98fe-4be9-e6daa14835c7 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 93C4:146594:246345:32FA5F:697886EB |
| html-safe-nonce | 607c517c4ef49b3d047629da58c2f3aa5e708d8976d9453a9e9f5863f1c55bac |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5M0M0OjE0NjU5NDoyNDYzNDU6MzJGQTVGOjY5Nzg4NkVCIiwidmlzaXRvcl9pZCI6IjYzMzgzMTE2MTI0Nzc3Njk0NTEiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | bb3b5b0937661978e35f0ae56d66aacd4a3366f68f9e7e2ffa71a942d6b12c1a |
| hovercard-subject-tag | issue:1203323653 |
| 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/2532/issue_layout |
| twitter:image | https://opengraph.githubassets.com/092753ce4cb95e8e64f398db9b203b7ca994559705c68720a4f86bf75484177b/feast-dev/feast/issues/2532 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/092753ce4cb95e8e64f398db9b203b7ca994559705c68720a4f86bf75484177b/feast-dev/feast/issues/2532 |
| og:image:alt | Expected Behavior Retrieving training data from an offline store that is BigQuery by using get_historical_features method from Python SDK. Current Behavior Getting this error when running get_histo... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | KarolisKont |
| hostname | github.com |
| expected-hostname | github.com |
| None | 2981c597c945c1d90ac6fa355ce7929b2f413dfe7872ca5c435ee53a24a1de50 |
| 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 | 73a426593e896c8afeb40b1706b74d04068aca2d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width