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
Search updates #8570
Search updates #8570
Conversation
Update all channel references to use useChannels.
Consolidate search chips in SearchChips component.
Cleanup nonexistent prop.
Clean up lock file. Add additional nonconforming keys.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @rtibbles. I haven't managed to understand and review all parts of this PR yet. I added some comments to parts that I went through in more detail and I also see the following issues:
1. I can't remove search by clicking on the delete button in a search chip
2. Navigation from a channel card to a channel page on the home page stopped working
3. Home page and classes pages content area is wider, is that change intentional?
Before | After |
---|---|
Thanks @MisRob:
Looks like this was specific to key word searches only. Was unable to replicate with a non-keyword search item.
This is probably related to the route simplification, will fix.
This was not intentional - it's the result of slightly overzealous LearnIndex cleanup. Will revert. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am going to do a closer code read-through (I've done a quick pass to understand the general changes). Overall the changes look good, although I appreciate that @MisRob is able to weigh in on the composables because I'm not sure I would things there.
The one bug I've noticed in manual QA is that the options for the filter options persist the previous state after clearing the search:
Will update with additional questions/comments this afternoon after a closer code review.
Ah yes - good catch, can clear labels too on search change. |
Remove width setting only used by non-existent route. Remove TOPICS_CHANNEL and TOPICS_ROOT references. Fix JS tests.
Remove breadcrumbs reference to Library.
Resolved review feedback, except for adding tests for the search composable. |
Tests for search composable have now been added. |
kolibri/plugins/learn/assets/src/composables/__tests__/useSearch.spec.js
Show resolved
Hide resolved
Seems like feedback has been addressed, although I know @jtamiace sent some feedback about the homepage -- not sure if that will be included in this PR or not. Otherwise, the only thing I see is this "extra chip" popping up. Seems like one empty one is appended to the end of the list of filters. |
I think best to do as a follow up. The extra chip is probably coming from an empty |
Replicated and updated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code look good. I really love seeing the composition API stuff in action and seeing it mixed with Vuex stuff - love it. I didn't see anything that jumped out at me.
I found a bug in the keywords processing in Python which is that it fails with the following queries, separated by line:
10
100
hello 10
hello 100
10 hello
10 x 10
10 10 10
100 10 100
or
and or
These are all unlikely queries, of course, but they may signal that there are more that I'm not finding. I wouldn't block merging on this but it's worth following up on, perhaps after bug bash to see if people run into any more normal queries that return 500.
The server gives a message from Django that it needs to be valid JSON (traceback).
In any case - the fail state there when it gets the 500 is to show a spinner forever so that could use some better error handling for the UX - maybe just showing 0 results along with some existing "we encountered an error" strings. The user can return to normal by clearing the filters that appear once you click something in the side bar.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh just noticed this as I was wrapping up but the X shows in the search bar when you haven't searched any kind of text query.
So - I click "Read" and the X shows in both searches (top bar and left nav).
When I click it, nothing happens. This is actually a bug altogether - even when I type text in and click the X to clear the search, it doesn't have any effect on the chips or query results.
If this isn't in scope I can make sure to create a follow up issue.
Fixed the 500 in #8579 Have fixed the search box |
Requested changes have been added
Summary
References
Fixes #8565
Fixes #8555
Fixes #8556
Fixes #8557
Also resolves some TODOs from #8563:
Reviewer guidance
Testing checklist
PR process
Reviewer checklist
yarn
andpip
)