Magento Tutorials

Exception printing is disabled by default for security reasons

What is “Exception printing is disabled by default for security reasons”?

As explained in this similar tutorial There has been an error processing your request, this is a common error message that you will encounter when working with Magento. Note that the message in itself is NOT an error, but rather a notification on some errors occurring in your system. As it is caused by potential conflicts between internal components of Magento and/or caching issues, you may encounter this error message when installing a new Magento theme/module.

magento exception printing

How to solve this?

First, if you’re not involved with managing your server and your Magento backend, it might be worth it to check with your developers to see if they’re doing on the Magento backend. It is likely that your developers might be troubleshooting things on your Magento backend which leads to this error message.

In short, there are two main ways to solve this error message: (1) clear your cache and (2) enable printing errors. Now we’ll go into details on each solution.

1. Clear your cache

Clearing your cache oftentimes can make this error message go away for good.  To clear your cache, access your Magento installation folder, go to var/cache and delete all the files there.

magento cache folder

Alternatively, you could also go to your Magento admin and navigate to System > Cache Management > Flush Cache Storage.

Flush cache storage Magento 2

Then, refresh your Magento site to see if the error message is gone.

Don’t skip this guide to know how to Enable/Disable OR Clear Cache in your Magento 2-based online stores.

2. Enable exception printing errors

If the above method doesn’t work, then you need to enable printing errors to find out what the exact problems are and solve them.

To enable printing errors, first you’ll need to switch your store to developer mode using:

php bin/magento deploy:mode:set developer

And then, go to the /pub/errors folder in your Magento 2 directory and change the name of this file:

local.xml.sample

to local.xml.

Next, refresh your error page and you should be able to see a list of errors like so:

[2020-12-12 22:35:20] main.CRITICAL: Class Magento\Framework\App\Http\Interceptor does not exist {"exception":"[object] (ReflectionException(code: -1): Class Magento\\Framework\\App\\Http\\Interceptor does not exist at /home/public_html/vendor/magento/framework/Code/Reader/ClassReader.php:24)"} []

Now you have the specific errors you need to debug! And in case you find it too confusing, don’t hesitate to ask for help in the comment section below.

If you want to find out more about Magento 1 & 2, we have exclusive tutorials for you to learn all about this amazing platform.

Dom

A knowledge craver who always strive to be wiser everyday.

Subscribe
Notify of
guest

14 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments
Siyakant chaudhary
Siyakant chaudhary
4 years ago

Good information i have also apply your tips then solve my error.Thank you for sharing.Keep it up

Edouard Tabary
3 years ago

Thanks You ! I was able to restart my site by emptying the cache, for the manipulation of renaming local.xml.sample to local.xml, as I’m not a computer scientist, I’m afraid to take the risk even if it tempts me!

mithlaj
mithlaj
2 years ago

nice … I just solved the error…. after changing the file name .sample to .xml. then the page started working perfectly. I dont get any error after that . (Next, refresh your error page and you should be able to see a list of errors like so: – no error shown.. worked perfectly)

Omowunmi Rachael Ekun
Omowunmi Rachael Ekun
5 years ago

Thank you very much, this worked for me

SHEILA
4 years ago
Reply to  Dom

HI I CAN’T SEEM TO CLEAR MINE STILL SHOWING EVEN MORE ERROR THAN BEFORE

aejaz khan
aejaz khan
4 years ago

Hey Dom,

Thanks, It’s worked for me.

Appreciated

princy p
princy p
3 years ago

Not working
Same issue

Last edited 3 years ago by princy p
asad waseem
3 years ago

There has been an error processing your requestException printing is disabled by default for security reasons.
Error log record number: 544949476612

how to solve this error

raja
raja
2 years ago

i’m getting these errors ==>

1 exception(s):
Exception #0 (Exception): Notice: Trying to access array offset on value of type null in C:\xampp\htdocs\pharmacyrx\vendor\magento\framework\App\AreaList.php on line 78

Exception #0 (Exception): Notice: Trying to access array offset on value of type null in C:\xampp\htdocs\pharmacyrx\vendor\magento\framework\App\AreaList.php on line 78

#1 Magento\Framework\App\AreaList->getCodeByFrontName('') called at [vendor\magento\framework\App\Http.php:111]
#2 Magento\Framework\App\Http->launch() called at [generated\code\Magento\Framework\App\Http\Interceptor.php:24]
#3 Magento\Framework\App\Http\Interceptor->launch() called at [vendor\magento\framework\App\Bootstrap.php:261]
#4 Magento\Framework\App\Bootstrap->run(&Magento\Framework\App\Http\Interceptor#0000000070c086f500000000325ddf58#) called at [index.php:39]
Haroon
1 year ago

i changed local.xml.sample

then my site admin/system_config/ path show

somes codes..

Please tell what next i do?

Neol Naan
1 year ago

Nice blog, it provides many informative and helpful information. Thanks for sharing this. Looking for more updates in future.

Deepak Tiwari
Deepak Tiwari
1 year ago

pls call me 6265630540