I updated my Magento 2.4.1 installation to 2.4.2 a while ago.
Since then it works as expected. No problems.
But now I discovered that wenn I call magento setup:upgrade the update starts and after all finishes, I can’t see the options in my configurable products (sizes, colors,…). They are just gone. I have no clue why.
Before the upgrade
After the upgrade
The configuration options are missing after the upgrade and the console shows me an error which was not present before.
…/static/version1623092606/frontend/Magento/luma/de_DE/configurableVariationQty.js
And I can’t find a file called configurableVariationQty.js
anywhere on my server. Where does it come from? Should it have been installed with the upgrade?
Does anybody have a clue what’s going on here? How can I gather more information?
2
Answers
Tracked it down finally.
This issue helped me find the solution: https://github.com/magento/inventory/issues/3276
The patch, referenced in the last post (https://github.com/magento/inventory/commit/337f8b7d56d81c217d5bf2bac180b315fd6120d0#diff-669c3cc08f646d82fcfa47b2385c3301fb1ee58c863ab0c91812e9e0482d8569) helped me to solve my problem.
InventoryCatalogFrontendUi/Model/GetProductQtyLeft.php
already looked like the patched version in my installation.But I had to patch
InventoryConfigurableProductFrontendUi/view/frontend/web/js/configurable-variation-qty.js
in my installation.After adding the
&& response.qty > 0
all worked well again.This error was gone and the configurable options showed up again.
If you are running production mode (see
bin/magento deploy:mode:show
), you need to runbin/magento setup:static-content:deploy
after setup:upgrade, as well.It might also be needed to reindex with
bin/magento indexer:reindex
.