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

Upgraded concrete5 caused duplicated results of topic filter #4907

Closed
katzueno opened this issue Dec 28, 2016 · 11 comments
Closed

Upgraded concrete5 caused duplicated results of topic filter #4907

katzueno opened this issue Dec 28, 2016 · 11 comments
Labels
Type:Bug Existing functionality not performing as expected.

Comments

@katzueno
Copy link
Contributor

katzueno commented Dec 28, 2016

This may be related to upgrade script.

Steps to Reproduce

  • Build a site with 5.7.x (5.7.5.13) with sample contents installed
  • Duplicate 3 blog posts 7 times. (Total 21 pages)
  • Upgrade the site to 8.0.3
  • Go to blog index page and try the topic search, you get duplicated results

duplicated-result

  • Go to "A Beautiful Site Deserves a Beautiful Blog" post. Then, you see multiple "project" topics in Topics list.

duplicatedtopislist

*When I upgrade my company web site, "Related Posts" also gets multiple results as well.

@katzueno
Copy link
Contributor Author

UPDATE:

If I update those existing blog and publish as a new version, these duplicated result disappears.

@s-hiroshi
Copy link

I support this issue

1 similar comment
@aniya
Copy link

aniya commented Jan 5, 2017

I support this issue

@aembler aembler added Status:Available Reviewed issue, it’s real, we’d review a pull request. Type:Bug Existing functionality not performing as expected. labels Jan 10, 2017
@aembler aembler modified the milestones: 8.0.4, Future, 8.1 Jan 10, 2017
@aembler
Copy link
Member

aembler commented Jan 13, 2017

This would be best served by a community pull request.

@electroflame
Copy link

electroflame commented Feb 13, 2017

I got hit by this (thankfully on a small site!) so I definitely support this issue.

As a workaround, @katzueno's method of republishing the affected pages as new versions totally works. However, I found it to be much faster (and easier) to go to the Sitemap and edit the Attributes of each affected page. Simply toggling (deselecting and then reselecting) the page's topics (and then saving) seemed to have fixed those pages.

I can't imagine using either method on a large site, though. (I handled ~50 pages) As a short-term workaround, though, they'll work in a pinch.

@hissy
Copy link
Contributor

hissy commented Jun 16, 2017

I've found the reason of duplicated topic node

https://github.com/concrete5/concrete5/blob/a57ec9715e6cb0cabf8f625b88cdc4e6c86c1d94/concrete/src/Updater/Migrations/Migrations/Version20160725000000.php#L310

"select * from CollectionAttributeValues where akID = ?" should be "select * from CollectionAttributeValues where akID = ? group by avID"

@hissy
Copy link
Contributor

hissy commented Jun 16, 2017

This would be best served by a community pull request.

Our team (concrete5 japan) is now working on this issue, but how we can fix it? I think we can fix Version20160725000000 class, but should we add new migration class for already upgraded sites? Or, should we provide the way to fix the issue like as a package?

@aembler
Copy link
Member

aembler commented Jun 16, 2017 via email

@joe-meyer
Copy link
Contributor

I don't think we can use select * from CollectionAttributeValues where akID = ? group by avID, that doesn't seem like something mysql strict mode would like very much. SELECT DISTINCT akID, avID, atID FROM CollectionAttributeValues where akID = ? (or instead of distinct if you want to use group by that would probably work.

At any rate, does anyone have a mysql cleanup script available for this yet?

@joe-meyer
Copy link
Contributor

@hissy did you guys have any luck coming up with a fix for this?

@electroflame
Copy link

Any updates on this issue (or any of the potential fixes)? It's a pretty major problem when upgrading semi-large to large sites, as all the pages have to be updated by hand.

It's currently preventing a couple of my sites from being upgraded to any current 8.x version, as it's easily a few hours of work to manually update the pages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type:Bug Existing functionality not performing as expected.
Projects
None yet
Development

No branches or pull requests

8 participants