Setup Upgrade Fails when Module is Enabled
NathanDayMF opened this issue · 6 comments
Preconditions
Magento Version: OS 2.3.4
Module Elasticsuite Cms Search Version : 2.2.6
Environment : Developer
Third party modules : N/A
Sample Data Enabled
Steps to reproduce
- php bin/magento mod:en Smile_ElasticsuiteCms
- php bin/magento setup:upgrade
Expected result
- setup:upgrade completes with no errors
Actual result
- setup:upgrade fails with error
Incorrect theme identification key
onModule 'Magento_ConfigurableSampleData': Running data recurring...
after a bit of debugging issue is thrown during Smile\ElasticsuiteCms\Model\Page\Indexer\Fulltext\Action\Full::rebuildStoreIndex
commenting out $this->areaList->getArea(Area::AREA_FRONTEND)->load(Area::PART_DESIGN);
within the aforementioned function allows the setup:upgrade
to complete, can anyone explain why this line is needed?
I'm able to reproduce this on an existing project having a custom theme defined.
However, I'm not able to reproduce it on a raw Magento install (with Luma theme).
So that's a first insight, I'm gonna dig more on this one.
Regards
Looks like this : https://magento.stackexchange.com/questions/291609/incorrect-theme-identification-key
And this : magento/magento2#27180
The ConfigurableSampleData module does trigger a full reindex, which is an idiotic behavior.
It's doing this by emulating the crontab
area which would fail if there is no theme defined for crontab
.
I don't see much to do more than handling silently this exception in such case.
Fixed, I release a minor 2.2.7
@romainruaud
Hi there,
seems like your commit has not found its way into 2.2.8? Why? 🤔
See: https://github.com/Smile-SA/magento2-module-elasticsuite-cms-search/blob/2.2.8/Model/Page/Indexer/Fulltext/Action/Full.php
So in other words, I got the same error when installing version 2.2.8. If I downgrade to 2.2.7 everything works fine 😅
Thanks for checking it again in advance.