Dani1989 Posted November 23, 2019 Share Posted November 23, 2019 Hello, I've got a weird problem. When a customer makes an order and successfully pays, that order gets the status Payment Received. This status is set to generate both invoice and delivery slip. When debug mode is enabled, this the invoice and delivery slip are NOT generated. If I switch the order to another status, then they get generated and I can open them without an issue. This only happens when debug mode is enabled. When production mode is enabled, then everything works good. Any ideas what might be causing this problem or what the solution could be? Thanks! Link to comment Share on other sites More sharing options...
El Patron Posted November 23, 2019 Share Posted November 23, 2019 never run debug mode unless actively debugging as the output from debug can break many things. the fix = disable debug mode, or add hack for debug enabled on specific IP Link to comment Share on other sites More sharing options...
Dani1989 Posted November 23, 2019 Author Share Posted November 23, 2019 Hi, thank you for taking time to help me out. I am upgrading the site for a client and installing a new theme hence why debug mode is enabled on a backup of the live site. I don't have any modules installed that modify the Invoice or DS process. Are you saying that the output from the Debug Mode can break even the original methods of PrestaShop? Link to comment Share on other sites More sharing options...
tuk66 Posted November 24, 2019 Share Posted November 24, 2019 Debug mode in 1.7 is devil. It can break even perfectly working page because of unimportant PHP Notice. If you want to play with it, try to set different $errorReportingLevel default value: public static function enable($errorReportingLevel = E_ERROR, $displayErrors = true) in the /vendor/symfony/symfony/src/Symfony/Component/Debug/Debug.php file. 1 Link to comment Share on other sites More sharing options...
Dani1989 Posted November 24, 2019 Author Share Posted November 24, 2019 Ok, thank you both! Link to comment Share on other sites More sharing options...
El Patron Posted November 24, 2019 Share Posted November 24, 2019 we no longer use ps debug mode but wrote in-house module that reports all php/.js errors etc. to rollbar.com. So we never need to enable ps debug mode. Link to comment Share on other sites More sharing options...
pycode.biz Posted November 24, 2019 Share Posted November 24, 2019 Its normal thing. Debug mode sending data with http headers before you're able to download PDF. In production servers you should use some APM like newrelic, sentry or elastic APM for handling errors Link to comment Share on other sites More sharing options...
tuk66 Posted November 25, 2019 Share Posted November 25, 2019 Of course, you are professionals, but my note generally goes to PrestaShop for normal people, where debug mode is useless. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now