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

Tags will not be synced to search plugin when adding new question #696

Closed
hgaol opened this issue Dec 26, 2023 · 3 comments · Fixed by #697
Closed

Tags will not be synced to search plugin when adding new question #696

hgaol opened this issue Dec 26, 2023 · 3 comments · Fixed by #697
Labels
bug Something isn't working good first issue Good for newcomers
Milestone

Comments

@hgaol
Copy link
Member

hgaol commented Dec 26, 2023

Describe the bug
when adding a new question, the corresponding tags will not be synced to search plugin because the TagRel entities have not been created yet.

To Reproduce
Steps to reproduce the behavior:

  1. enable one of the search plugin, e.g. elastic search
  2. enable the search plugin in Admin page.
  3. add a new question with tags.
  4. after question created, you can find that the tags have not been synced to the search plugin.

Expected behavior
question as well as its tags are all synced to search plugin. The root cause is that the TagRel entities are not been created yet when updating search.

Screenshots
If applicable, add screenshots to help explain your problem.

Platform (please complete the following information):

  • Device: [Desktop]
  • OS: [Windows/WSL]
  • Browser [chrome]
  • Version [main branch]
@LinkinStars
Copy link
Member

@hgaol Thanks for the feedback. This is indeed a bug. It should sync the data of the question to the plugin once again after creating the relation between the question and the tag.

@LinkinStars LinkinStars added this to the v1.2.5 milestone Dec 26, 2023
@hgaol
Copy link
Member Author

hgaol commented Dec 26, 2023

Thanks @LinkinStars ! I've created a PR to fix this issue.

BTW, one thing makes me little confused that which branch should I baded on when working on a feature or bug fix? I'm not sure main or dev. Because I saw commits from dev branch have been merged into my branch for this PR. If dev branch is the recommended one, I can directly fork and develop based on it.

@LinkinStars
Copy link
Member

Thanks @LinkinStars ! I've created a PR to fix this issue.

BTW, one thing makes me little confused that which branch should I baded on when working on a feature or bug fix? I'm not sure main or dev. Because I saw commits from dev branch have been merged into my branch for this PR. If dev branch is the recommended one, I can directly fork and develop based on it.

Thank you for your contribution and we will be reviewing it ASAP. The difference between the mai and dev branch is simple: the main branch goes straight to the latest release(v1.2.1), whereas dev goes to the next release(v1.2.5). If we set a milestone(v1.2.5) for this issue to be fixed in the next release, so it's better to start development base on the dev branch.

kumfo added a commit that referenced this issue Dec 26, 2023
#697)

fix #696 .

changes,
1. change `qr.updateSearch` to `qr.UpdateSearch` to make it accessible
outside.
2. update search (search plugin) after updating or adding records in the
`TagRel` table.

---------

Signed-off-by: Adam Vollrath <[email protected]>
Co-authored-by: sy-records <[email protected]>
Co-authored-by: Adam Vollrath <[email protected]>
Co-authored-by: kumfo <[email protected]>
@LinkinStars LinkinStars moved this from Todo to Done in Answer Roadmap Dec 26, 2023
@hgaol hgaol closed this as completed Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants