3

I have recently upgraded my site from Magento 2.2.6 to Magento 2.3.2. During each di compilation it shows a warning like

main.INFO: Reference to undeclared plugin with name 'stockedProductsFilterPlugin'. [] []

When i debugged this case and i found that in Magento 2.3.0 there was a plugin available with this name in 'module-elasticsearch' module and in Magento 2.3.2 they have removed that plugin and definition from that module. But in the module 'module-inventory-elasticsearch' they are written to disable that plugin which is currently not existing like below.

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
<type name="Magento\CatalogSearch\Model\Indexer\Fulltext\Action\DataProvider">
    <plugin name="stockedProductsFilterPlugin" disabled="true"/>
    <plugin name="stockedProductFilterByInventoryStockPlugin" type="Magento\InventoryElasticsearch\Plugin\CatalogSearch\Model\Indexer\Fulltext\Action\DataProvider\StockedProductFilterByInventoryStock"/>
</type>

So since there is no definition for that plugin this warning is showing. So how we can remove this warning from di compile. When i removed the disabling code from this module the warning will gone. But we are not supposed to edit the magento core files. Also another way i found create a dummy plugin with the same name, but this is a bad way. Any other solution for this?

  • When i checked this case in a fresh magento 2.3.2 version, no such warning is shown while the di compile. I dont know why this happening for my upgraded system. Its not related to any third party or custom module because i have disabled all such modules and tried the di compile, but still the warning is showing. – amesh Jul 17 at 11:12
  • Did you find a solution to this please? I am having same issue – G. G. Jul 29 at 18:18
  • 1
    We could not get a solution from magento side. We have just created a patch to remove this code from the di.xml file. Since there is no definition for this plugin is given anywhere, we not need this. If you follow this method just remember about this patch while upgrading the magento. – amesh Jul 30 at 7:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.