Visitar URL original
fix: Check for snowflake functions when setting up materialization engine by benchoncy · Pull Request #4456 · feast-dev/feast · GitHub
Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Refactor stage_list to function_list
Signed-off-by: Ben Stuart <ben@benstuart.ie>
  • Loading branch information
benchoncy committed Aug 27, 2024
commit 02ec6ad836c769df4debcd2363a45d715474fa67
4 changes: 2 additions & 2 deletions sdk/python/feast/infra/materialization/snowflake_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,14 @@ def update(
with GetSnowflakeConnection(self.repo_config.batch_engine) as conn:
query = f"SHOW USER FUNCTIONS LIKE 'FEAST_{project.upper()}%' IN SCHEMA {stage_context}"
cursor = execute_snowflake_statement(conn, query)
stage_list = pd.DataFrame(
function_list = pd.DataFrame(
cursor.fetchall(),
columns=[column.name for column in cursor.description],
)

# if the SHOW FUNCTIONS query returns results,
# assumes that the materialization functions have been deployed
if len(stage_list.index) > 0:
if len(function_list.index) > 0:
click.echo(
f"Materialization functions for {Style.BRIGHT + Fore.GREEN}{project}{Style.RESET_ALL} already detected."
)
Expand Down