Hot answers tagged


Run this command: php bin/magento list When everything is working correctly, this should list out all of the possible commands in your Magento 2 command line interface. However, in the event that something is going wrong, this will also give you a much more descriptive error message about how and why it is failing. This could be the result of an invalid ...


It's similar to Magento 1, but local.xml.sample is located in pub/errors. Just rename local.xml.sample to local.xml within pub/errors directory.


Magento using full path urls to access CSS files is a common error that results from two things happening: Having Merge CSS Files Enabled Magento being unable to read/write to the media/ folder. To fix this issue, please ensure that: The media/ folder exists in your Magento installation. The media/ folder is writable by your web server. As @flochtililoch ...


I don't know exactly HOW it happened, but in my scenario the core_config_data table was corrupted. It had added a new row somehow with path set to general and value set to NULL: This caused Magento\Framework\App\Config\ScopeConfigInterface::getValue() on public/vendor/magento/framework/Stdlib/DateTime/Timezone.php::scopeDate() to return NULL instead of ...


Have you switched off and cleared compilation? via the console/ssh you can use $ php -f shell/compiler.php -- disable $ php -f shell/compiler.php -- clear $ php -f shell/compiler.php -- compile $ php -f shell/compiler.php -- enable might need the fourth line...not sure. It might be a problem with the line that comes before the code you showed $...


The call Mage::throwException is used to throw exceptions of the specific Mage_Core_Exception variety. These are generally used to present error messages to the end user. For examples of this, do a quick search for Mage::throwException in the Mage_Checkout module, you'll find many instances where the error message is actually being translated before it's ...

34 Due to uniform variable syntax the code is now interpreted strictly from left to right. The line $params['object']->$params['method']($this->_file['tmp_name']); should be $params['object']->{$params['method']}($this->_file['tmp_name']); ...


I have solved this problem by just simply doing this steps. follow steps : Delete the "di" folder located in var directory (for 2.0 and 2.1) Run this command and go to your project root folder command: cd /yourmagentoroot/ If your Magento mode is developer then you don't need to run below commands just remove var/generation directory(2.0 & 2.1) or ...


$connection need to be an instance of \Magento\Framework\DB\Adapter\AdapterInterface, so update your __contruct() like this public function __construct( ... \Magento\Framework\DB\Adapter\AdapterInterface $connection = null, ... ) { ... }


Giving full control (read/write/execute) to var and pub directory solved this issue for me. sudo chmod -R 777 var pub Or, you may also try running the command using sudo. sudo php bin/magento setup:upgrade Also, try clearing cache. sudo rm -rf var/cache/* var/generation/*


This an incompatibility issue between PHP Version 5.4.4 and zend Framwork . Fixed it by change in this function lib/Zend/Pdf/FileParserDataSource.php. change abstract public function __construct(); to abstract public function __construct($filePath);


try to delete your module from the var/generation/vendor-name/your-module and try to refresh the page and check if it's working.


as stated correctly by Sander, deleted products still present in the product flat table cause this error. Anyway, truncating the whole table will not be necessary. You can find these products by this SQL-query: SELECT pf1.entity_id FROM catalog_product_flat_1 pf1 LEFT JOIN catalog_product_entity p ON pf1.entity_id = p.entity_id WHERE ISNULL( p.entity_id ) ...


Go inside root pub/errors folder, Just copy local.xml.sample to local.xml Also you can enable display_errors from app/bootstrap.php file. At line no. 11 remove # from the start of the line. Now the final statement displays as ini_set('display_errors', 1);


registration.php missing Apparently my Vendorname_Modulename module was missing the registration.php. I'm running the latest Magento2 version from GitHub. Every module has to register itself in the ComponentRegistrar. A typical registration.php for a module (in the root of your module) could contain: <?php use Magento\Framework\Component\...


Also happens when the module name in module.xml does not match with path based namespace. Please check your module name again: code/Vendor/myModuleName/etc/module.xml We can read more here:


Children of class Mage_Customer_Model_Customer should use getPasswordConfirmation() instead of getConfirmation() Upd: In class Mage_Customer_Model_Customer, method validate() was changed Before v1.9.1: $confirmation = $this->getConfirmation(); After: $confirmation = $this->getPasswordConfirmation();


Solved it! The increment_id column need to have the additional 'filter_index'=>'main_table.increment_id', So the Grid column now looks like this: $this->addColumn('order_id', array( 'header' => Mage::helper('sales')->__('Order Id'), 'align' =>'left', 'index' => 'increment_id', 'filter_index'=>'main_table....


I finally figure out the issue. I have to run composer install at <magento_dir>/update/.


Based on the stack trace you posted, it looks like this is happening when Magento is loading the layout update xml files, and using them to create the blocks which will render the HTML for the page. These lines appear to be the problem #1 /home/xxxxxxx/public_html/app/code/core/Mage/Core/Model/Layout.php(437): Mage_Core_Model_Layout->_getBlockInstance(''...


You have to first remove var folder. Run command, php bin/magento setup:di:compile After remove var folder give permission to var folder, chmod -R 775 var/generation/ var/cache/ var/full_page/ Check again.


It looks like something is breaking the adminhtml feed module. The cause could be a third-party module that is retrieving invalid XML. Check whether your site code contains any class which extends Mage_AdminNotification_Model_Feed. Once you find it: Try to disable that module (in app/etc/modules/). Clean the system.log. See if the error is gone. Repeat ...


In the table eav_attribute find rows with the field backend_model equal to given model and temporary remove them or change the model to the name of the existing class.


Your error comes from the fact that you're injecting \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig in the constructor whereas this class is already part of the parent Magento\Framework\App\Helper\AbstractHelper class. See the following from the parent class: protected $scopeConfig; public function __construct(Context $context) { $this-...


You've done the hard part, finding out how often they're used :) tl;dr: IMHO, you should use Mage::throwException most often, falling back to Mage::exception when you need to raise an exception type from outside of the scope of your module, if for no other reason than the session messaging ability and the fact that you don't have to type throw new in front ...


Magento in versions before CE 1.9 / EE 1.14 is not compatible with PHP 5.4 out of the box, which causes this error. Anyways, there is an official patch for this.


In your project open the file lib/Varien/File/Uploader.php and put a Mage::log() inside the save() function. public function save($destinationFolder, $newFileName = null) { $this->_validateFile(); if ($this->_allowCreateFolders) { $this->_createDestinationFolder($destinationFolder); } if (!is_writable($destinationFolder)) ...


Go to Below File /vendor/vertex/module-tax/Model/FlexField/Processor/OrderCurrencyGetterProcessor.php At the end of the "use" clauses in add the following two lines: use Vertex\Tax\Model\FlexField\Processor\InvoiceFlexFieldProcessorInterface; use Vertex\Tax\Model\FlexField\Processor\TaxCalculationFlexFieldProcessorInterface;


Most of the time these type of errors come when you try to install magento2 previously and it was failed due to some reason. and you have started your installation process again after removing all of the previous installed files and removed old database entry. So, to overcome this issue, before starting your installation process, just remove your browser's ...


Rename the local.xml.sample in /errors to local.xml and you would be able to see the error and the entire stack trace. Caution: This can lead to a security loop hole if used on a production server. Make sure you revert it once the error is resolved. PS: To be even more secure. Restrict magento access only to your IP while exception printing is enabled

Only top voted, non community-wiki answers of a minimum length are eligible