refactor: Convert legacy filter to be filter_query#128
Open
yuechao-qin wants to merge 1 commit intoycq/search-pipeline-run-created-byfrom
Open
refactor: Convert legacy filter to be filter_query#128yuechao-qin wants to merge 1 commit intoycq/search-pipeline-run-created-byfrom
yuechao-qin wants to merge 1 commit intoycq/search-pipeline-run-created-byfrom
Conversation
This was referenced Feb 26, 2026
Collaborator
Author
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
This was referenced Feb 26, 2026
f8f6e26 to
004fc05
Compare
df1b586 to
05e42b2
Compare
004fc05 to
64651a0
Compare
05e42b2 to
afa68d5
Compare
afa68d5 to
7b5d7cb
Compare
64651a0 to
bb02751
Compare
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.

TL;DR
Refactored legacy
filterquery parameter to befilter_queryJSON format.Before
filterGET /api/pipeline_runs/?filter=created_by:aliceGET /api/pipeline_runs/?filter=created_by:mefilter_queryGET /api/pipeline_runs/?filter_query={"and":[{"value_equals":{"key":"system/pipeline_run.created_by","value":"alice"}}]}After
filtercreated_by:aliceorcreated_by:meto be{"and":[{"value_equals":{"key":"system/pipeline_run.created_by","value":"alice"}}]}filter_queryno change.What changed?
Functional
filterandfilter_querybehaves the same.Other
_build_filter_where_clausesfunction with_convert_legacy_filter_to_filter_querythat converts legacy filter strings to filter_query JSON formatbuild_list_filtersto convert legacy filters to filter_query format and process them through the unified filter_query pipelinefilterasNoneand usefilter_queryfor all filtering operationscreated_byfilter values with a clear error message"me"value increated_by:mefilters is no longer resolved during conversion but handled downstream by_maybe_resolve_system_valuesHow to test?
created_by:alicefilterscreated_by:mefilters are converted but not immediately resolvedcreated_by:filters raiseApiValidationErrorNotImplementedErrorWhy make this change?
This change unifies the filter processing pipeline by converting legacy filters to the modern filter_query format, eliminating duplicate SQL generation logic and ensuring consistent behavior between legacy and modern filter formats.