Skip to content
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

feat: implicitCount added to content search index #35000

Closed

Conversation

ChrisChV
Copy link
Contributor

@ChrisChV ChrisChV commented Jun 17, 2024

Description

Adds implicit_count to content search index.

Supporting information

Testing instructions

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label Jun 17, 2024
@openedx-webhooks
Copy link

Thanks for the pull request, @ChrisChV! Please note that it may take us up to several weeks or months to complete a review and merge your PR.

Feel free to add as much of the following information to the ticket as you can:

  • supporting documentation
  • Open edX discussion forum threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here.

Please let us know once your PR is ready for our review and all tests are green.

@ChrisChV ChrisChV changed the title feat: implicitCount added to content serach index feat: implicitCount added to content search index Jun 17, 2024
@ChrisChV ChrisChV force-pushed the chris/FAL-3757-components-tab branch from ee5b26f to a7757d7 Compare June 17, 2024 16:08
Copy link
Contributor

@rpenido rpenido left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍 @ChrisChV ! Good work.

  • I tested this following the test instructions
  • I read through the code and considered the security, stability and performance implications of the changes.
  • Includes tests for bugfixes and/or features added.

@bradenmacdonald
Copy link
Contributor

Can't you just compute this from the response? The implicit_count should always be equal to tags.level0.length + tags.level1.length + tags.level2.length + tags.level3.length. So do we really need to store it in the index as a separate field?

@ChrisChV
Copy link
Contributor Author

Can't you just compute this from the response? The implicit_count should always be equal to tags.level0.length + tags.level1.length + tags.level2.length + tags.level3.length. So do we really need to store it in the index as a separate field?

Yes, it was one of my options, but I think that adding to the index would be the easiest way to obtain tag count without having to calculate it in all the responses that need the count tag. If you need the count tags it's easy to get it from the index. What do you think?

@bradenmacdonald
Copy link
Contributor

bradenmacdonald commented Jun 20, 2024

I think it's so simple to calculate that we might as well just calculate it ourselves when we need it. But if we need to sort by the tag count or filter by the tag count, then we definitely need to add to the index. If we don't need that, I wouldn't bother personally.

@ChrisChV
Copy link
Contributor Author

I think it's so simple to calculate that we might as well just calculate it ourselves when we need it. But if we need to sort by the tag count or filter by the tag count, then we definitely need to add to the index. If we don't need that, I wouldn't bother personally.

Make sense. Updated: open-craft/frontend-app-authoring@0843a1e

@ChrisChV
Copy link
Contributor Author

This index change is not longe necessary for now.

@ChrisChV ChrisChV closed this Jun 21, 2024
@openedx-webhooks
Copy link

@ChrisChV Even though your pull request wasn’t merged, please take a moment to answer a two question survey so we can improve your experience in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
open-source-contribution PR author is not from Axim or 2U
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants