-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
2.2.4: Wrong home page loaded in multi store setup #15245
Comments
@callumstar , not yet. If you would undo the changes from commit c18e36b, the right configuration values are loaded but that would be a very hacky workaround. |
@jokeputs I tried to revert this commit but still got the issue |
@jokeputs @callumstar - do you have any news related to this? We got the same issue in a MCE 2.2.4 store... You can see it in full effect on https://eu.makerdise.com. All links are wrong, some strings also. DAMN. |
Hi @gewaechshaus, I've heard nothing from @magento-team or @magento-engcom-team regarding this. Somebody has verified this is an issue in the GitHub Issue that I raised (please find it here - #15205), they mentioned that there is a commit that you can do to attempt a fix for it for the time being, so I would suggest trying that. We've taken the decision to not upgrade to 2.2.4 yet with any sites because of some of these frustrating bugs that have appeared in this version. |
Hi @callumstar, |
warning: core hack ahead ;) I managed to bypass the bug by adding the following in /vendor/magento/framework/Locale/Resolver.php
|
Hi @jokeputs. Thank you for your report.
The fix will be available with the upcoming 2.2.6 release. |
Let's quote from the PR to provide more accurate info:
|
Hi @jokeputs. Thank you for your report.
The fix will be available with the upcoming 2.3.0 release. |
Here is a slightly modified version for everyone who dont want to wait until 2.3:
Its a little bit better than the solution from @NicoDG , because there are no hardcoded stores. Still a bad core hack |
It's already fixed in 2.2.5 😉 Or if you are still on 2.2.4, you can use the official patch available over here: https://magento.com/tech-resources/download (MAGETWO-92926) |
i am still having this problem in 2.2.5, tried the fix mentioned above and there was no affect. does anyone have any ideal of where i should start to fix this? |
I also have the same problem in 2.2.5, none of the fix mentioned works. thanks for help |
Hello. @esiemens, @jfgalano did suggestion from @sidolov work for you? Also, could you try to reproduce issue on clean 2.2.5? I just tried and it seem to work. Please let me know. @EliasKotlyar, @NicoDG, @gewaechshaus, @callumstar, @LSERRE did you by any chance tried to reproduce this issue on 2.2.5? @jokeputs, @hostep from what I understand the fix in 2.2.5 work for you, but wanted to confirm. Please let me know. |
@melnikovi: I tested the fix when it was being developed, but never really tested 2.2.5 itself to see if the issue was actually resolved. |
Thank you for trying reproduce this issue on 2.2.5 and confirming that it's fixed @hostep. |
@melnikovi, yes the upgrade to 2.2.5 fixed the issue I had with the home pages. |
Preconditions
a. An international website with a store view with store code 'international'. This is your default website.
b. A website for Belgium with a store view with store code 'nl_be'.
a. A page that will be the home page for the international store view.
b. A page that will be the home page for the nl_be store view.
a. Use the international home page as your default configuration
b. Set the nl_be home page for the Belgian website
Steps to reproduce
Expected result
Actual result
Possible cause
I've already done some debugging and this commit seems to cause the issue: c18e36b.
Because
Magento\Framework\Session\Config\ConfigInterface
has been added as a constructor argument toMagento\Framework\App\Response\Http
,Magento\Framework\Session\Config
will be created during the$bootstrap->createApplication()
part ofpub/index.php
:Next
Magento\Framework\Session\Config
in its own constructor will callMagento\Framework\App\Config\ScopeConfigInterface
to get a configuration value. But the current store has not been determined yet at this point. This will only happen in the$bootstrap->run()
part ofpub/index.php
.Magento will fallback to the default store and this will cause the
$resolvedScopeCodes
array inMagento\Framework\App\Config\ScopeCodeResolver
to have a wrong value for keynull
. Which in turn will cause the wrong homepage being loaded for the nl_be store view.I'm willing to make a pull request for this but I don't see a good solution.
The text was updated successfully, but these errors were encountered: