Skip to content

Commit

Permalink
Fix count of the field from index (#243)
Browse files Browse the repository at this point in the history
  • Loading branch information
thanh-nguyen-dang authored Oct 10, 2023
1 parent 378ca4d commit 922fc51
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tube/etl/indexers/base/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,10 +215,11 @@ def get_type_of_item_for_list_type(self, node_label, src):
return a.get(src)

def get_prop_type(self, fn, src, node_label=None, index=None):
if fn is not None and fn in ["count", "sum", "min", "max"]:
return (float,)

if fn is not None and index is None:
if fn in ["count", "sum", "min", "max"]:
return (float,)
elif fn in ["set", "list"]:
if fn in ["set", "list"]:
if node_label is None or src == "id":
return (str,)
return self.get_type_of_item_for_list_type(node_label, src)
Expand Down

0 comments on commit 922fc51

Please sign in to comment.