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

CRITICAL: Records are translated only in collections #478

Closed
hnatt opened this issue Nov 14, 2014 · 1 comment
Closed

CRITICAL: Records are translated only in collections #478

hnatt opened this issue Nov 14, 2014 · 1 comment

Comments

@hnatt
Copy link
Contributor

hnatt commented Nov 14, 2014

This is a critical issue that renders master and stable branches unusable. I already wrote about it in comments to PR #444, but since it is closed I'd like to bring the problem closer to your attention.

How to reproduce:

  1. Install sample Spree application and configure it with SpreeI18n.
  2. Translate a product name.
  3. Visit products list page on frontend (list by taxon, or homepage if the product appears there), switch language and make sure the product name is being translated.
  4. Open the product page. The name is not translated. Desired result: the name should be translated.

Same thing with taxons. They are translated in lists (i.e. in the sidebar), but not when you open taxon page or a product page with the taxon in "bread crumbs".

To quickly fix this issue, you should roll back changes made by PR #444. This may decrease back the performance, but at least the gem will be usable again. I'm not arguing that before #444 there were too many redundant requests to DB, but that patch needs more work before being merged to stable branches.

I'll try to figure this out and fix it keeping the performance gain, but if someone of the maintainers of this great gem will happen to see this issue before I succeed (or if I fail completely), it would be great if it was fixed by a rollback to pre-#444 state.

I added a PR #471 with a test against this regression earlier.

@JDutil
Copy link
Member

JDutil commented Nov 25, 2014

Reverted back will open new issue to retry solving n+1 issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants