I noticed I am getting error in my magento 2.2.6 website's system.log continuously

[2021-09-16 10:10:56] main.CRITICAL: Invalid template file: 'Magento_catalog::product/list.phtml' in module: 'Magento_Catalog' block's name: 'category.products.list' [] []
[2021-09-16 10:10:56] main.INFO: 1 [] []
[2021-09-16 10:10:56] main.INFO: 1 [] []
[2021-09-16 10:10:56] main.INFO: 5 [] []

Please see my html\app\design\frontend\my_theme\default\Magento_Catalog\layout\catalog_category_view.xml

<?xml version="1.0"?>
 * Copyright © 2016 Magento. All rights reserved.
 * See COPYING.txt for license details.
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
        <referenceContainer name="page.top">
           <container name="category.view.container" htmlTag="div" htmlClass="category-view" before="breadcrumbs">
               <block class="Magento\Catalog\Block\Category\View" name="category.image" template="Magento_Catalog::category/image.phtml"/>
               <block class="Magento\Theme\Block\Html\Title" name="page.main.title" template="html/title.phtml" after="sidebar.main"/>
        <referenceContainer name="content">
            <block class="Magento\Cms\Block\Block" name="slide-category" before="-">
                    <argument name="block_id" xsi:type="string">slide-category</argument>
        <referenceContainer name="sidebar.additional">
            <block class="Magento\Cms\Block\Block" name="category-view-left-custom-block" after="-">
                    <argument name="block_id" xsi:type="string">category-view-left-custom-block</argument>
            <referenceBlock name="wishlist_sidebar" remove="true"/>
            <referenceBlock name="sale.reorder.sidebar" remove="true"/>

        <referenceContainer name="content">
            <referenceBlock class="Magento\Catalog\Block\Product\ListProduct" name="category.products.list" as="product_list">
                <action method="setDefaultDirection">
                    <argument name="dir" xsi:type="string">desc</argument>
        <move element="category.view.container" destination="content" before="-"/>

I can't find any error .Please help to solve this.


There is typo error in your xml file.

Magento_catalog::product/list.phtml should be Magento_Catalog::product/list.phtml

C should be capital in module name.

Just open catalog_category_view.xml from vendor/theme folder and update module name with capital.

You can also enable developer mode to see error on front if you are on local/development environment!

Hope above will help!

  • 1
    @AbilashErikson, welcome :) I will attempt magento.stackexchange.com/questions/347124/…
    – Pawan
    Sep 19 at 11:18
  • 1
    Your answer help me. But its not the same path you given . This is because of typo error in an extension . I search Magento_catalog in entire app/ code directory and fixed that issue. Sep 19 at 13:55
  • glad to know it worked!!
    – Pawan
    Sep 19 at 14:27

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.