You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is that the match of platform: win32 causes the referenced line to return False regardless of other filters.
But I think the core problem here is that the current task header matching does not allow for exclusion of multiple values for a specified field using a single filter. If this is addressed, then there would be no need for the return statement in line 238. This could be one of the issues with header matching that could be addressed by #245.
Please consider adding the following test case to tests/test_task_filters.py:
Hi,
I think there is a problem with this line in the Task's
matches_filters
function:https://github.com/CERT-Polska/karton/blob/master/karton/core/task.py#L238
I think the idea behind this line is that filters such as
don't make the Task's
matches_filters
function match for any arbitrary value ofplatform
.But I think this is a problem. Let's look at these example filters:
For the following three tasks, I would expect that the first one matches, the second one does not, and the third one does. But the first one does not:
The problem is that the match of
platform: win32
causes the referenced line to returnFalse
regardless of other filters.But I think the core problem here is that the current task header matching does not allow for exclusion of multiple values for a specified field using a single filter. If this is addressed, then there would be no need for the return statement in line 238. This could be one of the issues with header matching that could be addressed by #245.
Please consider adding the following test case to tests/test_task_filters.py:
The text was updated successfully, but these errors were encountered: