Source class "\Magento\CatalogRule\Api\Data\RuleLabelInterface" for "Magent o\CatalogRule\Api\Data\RuleLabelInterfaceFactory" generation does not exist .

  • Try to delete {{magento root path}}/var/generation/Magento then re-run php bin/magento setup:di:compile. – kunj May 14 '18 at 11:06

You can rename registration.php of module which is throwing compilation error.

Reference : Stack Exchange


Are you using custom code? Because RuleLabelInterface is part of the Magento_SalesRule-module, not the Magento_CatalogRule.

Try running setup:di:compile with the -vvv-argument to see the trace which is throwing the error. I'm guessing some module is instantiating the wrong class (and I doubt if it's Magento).

  • Yes,i make one custom module for catalogrule. – Lovely Setia May 14 '18 at 13:24
  • You're probably using Magento\CatalogRule\Api\Data\RuleLabelInterfaceFactory in your module instead of Magento\SalesRule\Api\Data\RuleLabelInterfaceFactory. (and for that reason probably also Magento\CatalogRule\Api\Data\RuleLabelInterface instead of ``Magento\SalesRule\Api\Data\RuleLabelInterface`. – Giel Berkers May 14 '18 at 13:31

Your Answer

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

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