Skip to content

fetch_historical_feature_values: unquoted BigQuery table name fails for project IDs like my-proj-5bb0 #7280

Open

Description

@naren-chennamsetty

Environment

  • google-cloud-aiplatform 1.165.1 and 2.7.0
  • vertexai.resources.preview.feature_store.offline_store.fetch_historical_feature_values

Problem

_feature_to_data_source in vertexai/resources/preview/feature_store/offline_store.py builds the feature source query as

f"FROM {fully_qualified_table}"

without backticks. BigQuery cannot parse an unquoted project ID whose segment after a dash starts with a digit, such as my-proj-5bb0, so the point-in-time query fails:

google.api_core.exceptions.BadRequest: 400 Syntax error: Expected ")" but got "bb0"

Steps to reproduce

  1. In a project whose ID has a dash followed by a digit-leading segment (for example my-proj-5bb0), create a FeatureGroup over bq://my-proj-5bb0.dataset.view and register features.
  2. Call offline_store.fetch_historical_feature_values(entity_df=..., features=[...]).

Expected

The query quotes the table reference:

f"FROM `{fully_qualified_table}`"

With that change the query runs and returns the expected point-in-time rows.

Workaround

Call with dry_run=True, add backticks around the table name in the printed query, and run it with bigframes.pandas.read_gbq_query.

Activity

  1. vanshhh18 commented on Nov 10, 2026

    @vanshhh18

    Hi, I'd like to work on this issue. I've identified that the BigQuery table reference is currently unquoted in _feature_to_data_source, which causes failures with project IDs containing hyphens. I'm working on a fix with a regression test for this case. Could you please assign this issue to me? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    api: vertex-aiIssues related to the googleapis/python-aiplatform API.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions