Skip to content

Commit

Permalink
fiddling
Browse files Browse the repository at this point in the history
  • Loading branch information
pauldambra committed Oct 20, 2024
1 parent d92924a commit a1ab553
Showing 1 changed file with 5 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,8 @@ def is_group_property(p: Property) -> bool:
return p.type == "group"


def is_dynamic_cohort_property(p: Property) -> bool:
return p.type == "cohort"


def is_static_cohort_property(p: Property) -> bool:
return p.type == "precalculated-cohort"


def is_cohort_property(p: Property) -> bool:
return is_dynamic_cohort_property(p) or is_static_cohort_property(p)
return "cohort" in p.type


class SessionRecordingQueryResult(NamedTuple):
Expand All @@ -54,7 +46,9 @@ class SessionRecordingQueryResult(NamedTuple):


class UnexpectedQueryProperties(Exception):
pass
def __init__(self, remaining_properties: PropertyGroup | None):
self.remaining_properties = remaining_properties
super().__init__(f"Unexpected properties in query: {remaining_properties}")


class SessionRecordingListFromFilters:
Expand Down Expand Up @@ -300,8 +294,7 @@ def _strip_person_and_event_and_cohort_properties(self, property_group: Property
if not is_event_property(g)
and not is_person_property(g)
and not is_group_property(g)
and not is_dynamic_cohort_property(g)
and not is_static_cohort_property(g)
and not is_cohort_property(g)
]

return (
Expand Down

0 comments on commit a1ab553

Please sign in to comment.