Repository navigation
fix(plugins): filter-bar BETWEEN is refused on Typesense and Weaviate and misrendered on BigQuery - #3193
Merged
Conversation
…value on Typesense, Weaviate and BigQuery
…trol MCP clients do not have
Signed-off-by: Ngô Quốc Đạt <datlechin@gmail.com>
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.
Summary
year is not a numeric field) and Weaviate (5,10 is not a number), and rendered on BigQuery as`n` BETWEEN '1,9' AND 9. The app sends a BETWEEN asvalue: "lower,upper"plussecondValue: upper, andTypesenseFilterBuilder.range,WeaviateFilterBuilder.betweenandBigQueryQueryBuilder.betweenClauseread the whole joinedvalueas the lower bound; each now strips the trailing,upperfirst, comparing Unicode scalars so a lower bound ending in a Prepend scalar such as U+0600 (which merges with the comma into oneCharacter) is still recovered.logic: "or"gets the message; it now states the limit, "Cassandra filters can only require every condition to match.", and names no control.Tests
Every BETWEEN test below builds the filter the way the app does, through
TableFilter.asPluginQueryFilter, or feeds that joined shape literally where the package cannot see the app. Each one fails without the fix.TypesenseFilterBuilderTests.buildsRangeFromAppEncodingTypesenseFilterBuilderTests.buildsRangeAfterSearchTagRoundTripTypesenseFilterBuilderTests.buildsNumericComparisons(its BETWEEN line now feeds"1937,1965")BigQueryQueryBuilderSQLTests.betweenFromAppEncodingBigQueryQueryBuilderSQLTests.betweenFromAppEncodingWithCommaBigQueryQueryBuilderSQLTests.betweenFromAppEncodingWithPrependScalarBigQueryQueryBuilderTagColumnTests.filterCarriesColumnsWeaviateFilterOperatorTests.betweenBoundsWeaviateFilterOperatorTests.betweenReadsLowerBoundOffJoinedValueWeaviateFilterOperatorTests.betweenRefusesPrependScalarLowerBoundAloneWeaviateSortTests.secondValueRoundTripsCassandraBrowseStatementTests.matchAnyRefusalNamesNoControlBigQueryQueryBuilderSQLTests.betweenFromJoinedValueAloneguards the existing fallback for a BETWEEN with no separate upper bound and passes with or without the fix.Docs
The docs rewrite branch covers the user-facing text.