label-studio-sdk icon indicating copy to clipboard operation
label-studio-sdk copied to clipboard

Bug: Applying filters to tasks.list doesn't work

Open svecile opened this issue 1 year ago • 4 comments

label-studio-sdk version: 1.0.5, label studio version: 1.13.1 (Docker deployment)

When i try to apply a filter it always returns all the tasks not just the one i'm filtering for and no error is received

filters = Filters.create(Filters.AND, [Filters.item(Column.inner_id, Operator.EQUAL, Type.Number, Filters.value(1))]) task = ls.tasks.list(project=project_id, query={"filters": filters})

Please let me know if you need more information.

svecile avatar Sep 12 '24 19:09 svecile

You need to supply a str for the query parameter. It should be query=json.dumps({"filters": filters}).

MmAaXx500 avatar Nov 08 '24 13:11 MmAaXx500

Hello,

I've got the same problem, @MmAaXx500 comment made is possible to fix this on my side. Maybe some example in the Docs might be useful.

amjadsaadeh avatar Nov 18 '24 12:11 amjadsaadeh

@MmAaXx500 thank you very much :)

ice6 avatar Nov 19 '24 14:11 ice6

@MmAaXx500 Thank you!

svecile avatar Nov 28 '24 19:11 svecile