Skip to content

Commit 0a3a70f

Browse files
committed
update filters
1 parent 3862419 commit 0a3a70f

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

python/lib/sift_client/resources/assets.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ async def list_(
7979
modified_by: Any | str | None = None,
8080
# tags
8181
tags: list[Any] | list[str] | None = None,
82-
_tag_ids: list[str] | None = None,
82+
_tag_ids: list[str] | None = None, # For compatibility until first class Tag support is added
8383
# metadata
8484
metadata: list[Any] | None = None,
8585
# common filters
@@ -103,7 +103,6 @@ async def list_(
103103
created_by: Filter assets created by this User or user ID.
104104
modified_by: Filter assets last modified by this User or user ID.
105105
tags: Filter assets with any of these Tags or tag names.
106-
_tag_ids: Filter assets with any of these Tag IDs.
107106
metadata: Filter assets by metadata criteria.
108107
description_contains: Partial description of the asset.
109108
include_archived: If True, include archived assets in results.

python/lib/sift_client/resources/runs.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,9 @@ async def list_(
153153
asset = cast("list[Asset]", assets)
154154
filter_parts.append(cel.in_("asset_ids", [a._id_or_error for a in asset]))
155155
if duration_less_than:
156-
raise NotImplementedError
156+
filter_parts.append(cel.less_than("duration_string", duration_less_than))
157157
if duration_greater_than:
158-
raise NotImplementedError
158+
filter_parts.append(cel.greater_than("duration_string", duration_greater_than))
159159
if start_time_after:
160160
filter_parts.append(cel.greater_than("start_time", start_time_after))
161161
if start_time_before:

0 commit comments

Comments
 (0)