-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Filtering by tags in query list is not working #4557
Comments
@kravets-levko @gabrieldutra at first I thought it's a backend issue, but this doesn't happen in the SaaS repo. Can it be related to one of he latest React changes? Maybe the Axios one? |
@arikfr Yes, seems it's related to Axios: it serializes arrays in a different way comparing to Angular:
When |
@kravets-levko is this something we can easily control? Otherwise we can update the backend to support it. |
Seems yes. I'll explore it a bit later (need to finish some work I already started) |
I checked in here, it seems we can change the serializer axios uses (we can pass it as a default config in the instance defined in {
paramsSerializer: params => qs.stringify(params),
} For qs I tested the LMK if you want me to push those changes or in case you already had another idea. |
* #4557 Tags filter doesn't work because of wrong query params format * Fix tests
Thanks for the quick fix! Great work y'all |
Quick bug - quick fix 😎 |
I think that this fix causes a bug in multi tag filter. I tried here and it's easy to reproduce. |
Can you provide more details? (e.g: in which url you tried it and what exactly happened) It looks like it's working in our preview environment |
It's not a bug, inspecting the source code, i seen that is used "contains" filter at: redash/redash/handlers/base.py Line 120 in a7ef3ad
I was expecting "any" behavior of tags filtering Thanks |
@ptsilva, yes, it evaluates as an "AND" 😅, I agree that the UI doesn't help much on reflecting the behavior (related: #2955), but in terms of the feature, in my personal experience it was much more valuable to have it working as is (with the "contains"). The scenario I had: more than 2k queries and needed a way to build a "Query Search" (text search is far too difficult in here). The combine tags search came in handy for this purpose as people could just go combining query tags to find their queries. Anyway, I think it makes sense to have a more robust search with more filtering options in the future. |
Interesting.. Perhaps adding "AND" or "+" between selected tags in not found message could reduce doubts related with tag filtering. But Anyway thanks for your reply! |
Issue Summary
A summary of the issue and the browser/OS environment in which it occurs.
Steps to Reproduce
I expect the queries list to filter by the selected tags, but this does not appear to be happening.
Technical details:
The text was updated successfully, but these errors were encountered: