Jump to content

PS 1.7.8.2 - Fatal Error if the website is put into debug mode (Fatal error: Uncaught Error: Class 'Db)


cwiz

Recommended Posts

Hi,

Can anybody help me please, I'm buidling a updated website to replace our live site that is running PS 1.6.1.24.

Everything has gone fine and but the site has now got a fatal error if I put the site in Debug mode from the BO, the only way to get the site viewable again is to edit the defines.inc.php file, changing debug back to false and then the site works fine again.

The below is the error that is given

Fatal error: Uncaught Error: Class 'Db' not found in /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/config/alias.php:47 Stack trace: #0 /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/config/alias.php(52): pSQL('configuration') #1 /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/classes/Configuration.php(155): bqSQL('configuration') #2 /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/classes/Configuration.php(209): ConfigurationCore::loadConfiguration() #3 /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/classes/PrestaShopAutoload.php(171): ConfigurationCore::get('PS_DISABLE_OVER...') #4 /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/classes/PrestaShopAutoload.php(130): PrestaShopAutoload->generateIndex() #5 [internal function]: PrestaShopAutoload->load('Db') #6 /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/config/alias.php(47): spl_autoload_call('Db') #7 /home/consolew/public_html/sonyplaystation in /home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/config/alias.php on line 47

 

Can anybody help please ? What is this stating the problem is?

I have disabled non native modules and overides and this hasnt changed anything.

Thank you 

 

 

Edited by cwiz (see edit history)
Link to comment
Share on other sites

  • cwiz changed the title to PS 1.7.8.2 - Fatal Error if the website is put into debug mode (Fatal error: Uncaught Error: Class 'Db)

Hi,

Thanks for the replies.

Its not the classic theme, its a Prestashop theme based on the Classic theme, it running on PHP 7.1.

If I migrate the existing ps 1.6 to ps 1.7 (starting from scratch) there is no error if placed in debug mode, so something has changed, but I've done so much work, this isnt realyy a place I'd like to be at to resolve the issue :(.

I've deleted the var/cache folder and this is the error message now 

Whoops, looks like something went wrong.

(1/1) RuntimeException

Failed to start the session because headers have already been sent by "/home/consolew/public_html/sonyplaystation4repairservice.co.uk/ps/override/classes/Link.php" at line 0.

in NativeSessionStorage.php line 150

at NativeSessionStorage->start()in NativeSessionStorage.php line 321

at NativeSessionStorage->getBag('attributes')in Session.php line 256

at Session->getBag('attributes')in Session.php line 280

at Session->getAttributeBag()in Session.php line 73

at Session->get('_security_main')in ContextListener.php line 91

at ContextListener->handle(object(GetResponseEvent))in WrappedListener.php line 46

at WrappedListener->handle(object(GetResponseEvent))in TraceableFirewallListener.php line 35

at TraceableFirewallListener->handleRequest(object(GetResponseEvent), object(Generator))in Firewall.php line 84

at Firewall->onKernelRequest(object(GetResponseEvent))in FirewallListener.php line 48

at FirewallListener->onKernelRequest(object(GetResponseEvent), 'kernel.request', object(TraceableEventDispatcher))in WrappedListener.php line 115

at WrappedListener->__invoke(object(GetResponseEvent), 'kernel.request', object(TraceableEventDispatcher))in EventDispatcher.php line 214

at EventDispatcher->doDispatch(array(object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener), object(WrappedListener)), 'kernel.request', object(GetResponseEvent))in EventDispatcher.php line 44

at EventDispatcher->dispatch('kernel.request', object(GetResponseEvent))in TraceableEventDispatcher.php line 143

at TraceableEventDispatcher->dispatch('kernel.request', object(GetResponseEvent))in HttpKernel.php line 127

at HttpKernel->handleRaw(object(Request), 1)in HttpKernel.php line 68

at HttpKernel->handle(object(Request), 1, false)in Kernel.php line 200

at Kernel->handle(object(Request), 1, false)in index.php line 82.

 

Weird thing is, if the site is not in debug mode, it appears okay, but obviously not.

What is the above error message trying to tell me ?

 

Thanks for your help

 

Link to comment
Share on other sites

But I have disabled all non native modules and the error still occurs.

Should I disable every module and then enable one at a time to highlight which is causing the error?

sorry I’m not a coder?

please advise

 

thanks 

Link to comment
Share on other sites

@Rhobur Thank you sincerely. I looked in Override/Classes and there was a link.php in the directory, if i editted this file, it was one module.

I deleted that module and now the site goes into debug mode without a problem.

I have spent hours on trying to resolve this and with your guidance its fixed - Truly cannot thank you enough.

All the best :)

 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...