fix: Centralize assignee filter parsing and accept frontend unassigned sentinel#2250
Merged
daryllimyt merged 1 commit intomainfrom Mar 4, 2026
Merged
Conversation
jordan-umusu
approved these changes
Mar 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
__UNASSIGNED__(in addition to legacyunassigned) for assignee filters and propagate that intent to service calls.Description
tracecat/cases/filters.pywhich implementsparse_assignee_filterand theUNASSIGNED_ASSIGNEE_IDENTIFIERSset and returns aParsedAssigneeFilterdict withassignee_idsandinclude_unassigned.tracecat/cases/router.pyandtracecat/cases/internal_router.pywith calls toparse_assignee_filterand wire the returnedassignee_idsandinclude_unassignedinto service calls._parse_assignee_filterimplementation and related duplication fromrouter.py.tests/unit/test_case_filters.pyto validate parsing behavior (legacy and frontend sentinels, mixed UUID + sentinel, and invalid identifier), and extendtests/unit/api/test_api_cases.pywith two tests to ensure the API accepts the frontend sentinel and forwards it into service method calls.Testing
pytest tests/unit/test_case_filters.pyand the new tests passed.pytest tests/unit/api/test_api_cases.py::test_search_cases_accepts_frontend_unassigned_sentinelandpytest tests/unit/api/test_api_cases.py::test_search_case_aggregates_accepts_frontend_unassigned_sentinel, and both passed.pytest tests/unit -qto validate the unit test suite for the changed modules and all tests completed successfully.Codex Task
Summary by cubic
Centralized assignee filter parsing and added support for the frontend "UNASSIGNED" sentinel so searches include unassigned cases correctly. This removes duplicated parsing in routers and ensures consistent service call parameters.
New Features
Refactors
Written for commit 5aafecd. Summary will update on new commits.