1

Changed the website/store codes on a multistore installation to something more meaningful/relevant. These new codes are saved in the database OK.

When i try to access websites/stores other than the default, i get a NoSuchEntityException error on the page thrown in the file: vendor/magento/module-store/Model/WebsiteRepository.php:80 The error info shows that it is still trying to use the old codes.

  • I have ran all the usual CLI commands: setup:upgrade, setup:di:compile, cache:flush, cache:clean, indexer:reindex

  • Ive deleted all the relevant folders in /var and /pub/static before running those commands

  • Restarted the server and run all the above again

  • Searched the server files and the database for references to the old codes

But the error still persists. Does anyone know what could be causing this? Where is it sourcing the old codes from? What do I need to do to get the new codes in the database to be used/recognised?

1 Answer 1

0

It seems this issue just relates to changing the website codes...not the store group/view codes. The website codes had the suffix: '_migrated'...maybe these are added to the codes when migrating data from m1 to m2...im unsure, as I did not perform the initial migration.

Anyway, changing just the non-default website codes back to their originals resolved this issue, and I can now access the non-default website stores again.

I still do not know where M2 was getting the old codes from when I was testing after changing the website codes.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.