Skip to content

Commit 3f784e2

Browse files
committed
sql
Signed-off-by: Tommy Hughes <tohughes@redhat.com>
1 parent 5d1b4fe commit 3f784e2

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

sdk/python/feast/infra/registry/snowflake.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -782,15 +782,13 @@ def _list_objects(
782782
"""
783783
df = execute_snowflake_statement(conn, query).fetch_pandas_all()
784784
if not df.empty:
785-
objects = [
786-
python_class.from_proto(
785+
objects = []
786+
for row in df.iterrows():
787+
obj = python_class.from_proto(
787788
proto_class.FromString(row[1][proto_field_name])
788789
)
789-
for row in df.iterrows()
790-
]
791-
for obj in objects:
792-
if not utils.has_all_tags(obj.tags, tags):
793-
objects.remove(obj)
790+
if utils.has_all_tags(obj.tags, tags):
791+
objects.append(obj)
794792
return objects
795793
return []
796794

0 commit comments

Comments
 (0)