如何在magento2中禁用编译器?

如何在magento2中禁用编译器?,magento2,Magento2,如何在magento 2.0中禁用编译器 我安装了Magento 2.0,然后从主题林安装了一个主题“Porto”。但是在安装主题之后,在编译时,我遇到了一个错误 magento_user:/var/www/html/magento2$ sudo php bin/magento setup:di:compile Compilation was started. Interception cache generation... 6/7 [========================>--

如何在magento 2.0中禁用编译器

我安装了Magento 2.0,然后从主题林安装了一个主题“Porto”。但是在安装主题之后,在编译时,我遇到了一个错误

magento_user:/var/www/html/magento2$ sudo php bin/magento setup:di:compile
Compilation was started.
Interception cache generation... 6/7 [========================>---]  85% 2 mins 418.2 MiBErrors during compilation:
        Smartwave\Filterproducts\Helper\Data
                Extra parameters passed to parent construct: $data. File: /var/www/html/magento2/app/code/Smartwave/Filterproducts/Helper/Data.php
        Smartwave\Filterproducts\Block\FeaturedList
                Incorrect dependency in class Smartwave\Filterproducts\Block\FeaturedList in /var/www/html/magento2/app/code/Smartwave/Filterproducts/Block/FeaturedList.php
\Magento\Framework\App\Config\ScopeConfigInterface already exists in context object
\Magento\Catalog\Helper\Image already exists in context object
        Smartwave\Filterproducts\Block\Home\FeaturedList
                Incorrect dependency in class Smartwave\Filterproducts\Block\Home\FeaturedList in /var/www/html/magento2/app/code/Smartwave/Filterproducts/Block/Home/FeaturedList.php
\Magento\Framework\App\Config\ScopeConfigInterface already exists in context object
\Magento\Catalog\Helper\Image already exists in context object
        Smartwave\Filterproducts\Block\Home\LatestList
                Incorrect dependency in class Smartwave\Filterproducts\Block\Home\LatestList in /var/www/html/magento2/app/code/Smartwave/Filterproducts/Block/Home/LatestList.php
\Magento\Framework\App\Config\ScopeConfigInterface already exists in context object
\Magento\Catalog\Helper\Image already exists in context object
        Smartwave\Filterproducts\Block\LatestList
                Incorrect dependency in class Smartwave\Filterproducts\Block\LatestList in /var/www/html/magento2/app/code/Smartwave/Filterproducts/Block/LatestList.php
\Magento\Framework\App\Config\ScopeConfigInterface already exists in context object
\Magento\Catalog\Helper\Image already exists in context object
Total Errors Count: 5
主题供应商说我需要禁用编译。在Magento 2.0中如何实现这一点

我在magento2文档中查找过这个,但找不到任何答案。我可以使用下面的命令禁用模块,但哪一个是编译器模块

sudo php bin/magento module:disable Magento_xxxx

如有任何帮助/建议,将不胜感激。“我的网站”现在已关闭,需要尽快将其打开。您不能禁用编译器。为什么主题开发者说要这么做?听起来很奇怪


在默认和开发人员模式下,编译器始终处于启用状态;一般来说,这是件好事。在生产模式下,编译器被禁用。但是在默认模式或开发人员模式下都无法禁用编译器。

公认的解决方案是无法禁用编译器。那么,您是如何解决这个问题的呢?供应商提供了一个更新版本,我没有在示例中遇到这个问题,因为我们的FE开发人员自己管理这个主题的编译。如果我们上传资产,则magento编译器无法编译更少的文件,如果我们删除的文件少于静态内容部署上的文件,则编译器正在搜索不存在的文件…下面是另一个供应商为magento 2.x提供错误说明的示例。在安装模块之前,说明“必须禁用Magento编译”。