Jump to content

Prestashop 1.7.6.1 Error 500


Recommended Posts

Hello,

I installed module 

"Pc builder

v1.1.4 - by Globo Jsc"

And now i getting error 500 on front store, and in back office in lot of tabs like innovice or product list etc. getting 

Oops! An Error Occurred

The server returned a "500 Internal Server Error".

Something is broken. Please let us know what you were doing when this error occurred. We will fix it as soon as possible. Sorry for any inconvenience cause

Before everything was fine .

Could you help me please?

https://nanite.net/

Front shop Error:

(1/1) FatalThrowableError

Parse error: syntax error, unexpected '{', expecting function (T_FUNCTION) or const (T_CONST)

in Cart.php line 14

at PrestaShopAutoload->load('Cart')in DebugClassLoader.php line 159

at DebugClassLoader->loadClass('Cart')

at spl_autoload_call('Cart')in FrontController.php line 333

at FrontControllerCore->init()in Controller.php line 273

at ControllerCore->run()in Dispatcher.php line 515

at DispatcherCore->dispatch()in index.php line 28

 

Back office Error:

Symfony\Component\Debug\Exception\FatalThrowableError

in override/classes/Cart.php (line 14)

    */

    public function getDeliveryOption($default_country = null, $dontAutoSelectOptions = false, $use_cache = false)

    {

        return parent::getDeliveryOption($default_country, $dontAutoSelectOptions, $use_cache);

    }

    {

        if (!Validate::isLoadedObject($this)) {

            return false;

        }

        $old_id = (int)$this->id;

        $newdata = parent::duplicate();

PrestaShopAutoload->load('Cart')in vendor/symfony/symfony/src/Symfony/Component/Debug/DebugClassLoader.php (line 159)

                    return;

                } else {

                    require $file;

                }

            } else {

                \call_user_func($this->classLoader, $class);

                $file = false;

            }

        } finally {

            error_reporting($e);

        }

DebugClassLoader->loadClass('Cart')

spl_autoload_call('Cart')in classes/Product.php (line 3172)

            * When called from the back office, cart ID can be inexistant

            */

            if (!$id_cart && !isset($context->employee)) {

                die(Tools::displayError());

            }

            $cur_cart = new Cart($id_cart);

            // Store cart in context to avoid multiple instantiations in BO

            if (!Validate::isLoadedObject($context->cart)) {

                $context->cart = $cur_cart;

            }

        }

ProductCore::getPriceStatic('1626', true, null, 2, null, false, false, 1, true, null, null, null, null, true, true)in src/Adapter/Product/AdminProductDataProvider.php (line 385)

                null,

                null,

                null,

                $nothing,

                true,

                true

            );

            if ($formatCldr) {

                $product['price'] = Tools::displayPrice($product['price'], $currency);

                $product['price_final'] = Tools::displayPrice($product['price_final'], $currency);

            }

AdminProductDataProvider->getCatalogProductList(0, 20, 'price', 'desc', array())in src/PrestaShopBundle/Controller/Admin/ProductController.php (line 154)

        $products = $productProvider->getCatalogProductList(

            $offset,

            $limit,

            $orderBy,

            $sortOrder,

            $request->request->all()

        );

        $lastSql = $productProvider->getLastCompiledSql();

        $hasCategoryFilter = $productProvider->isCategoryFiltered();

        $hasColumnFilter = $productProvider->isColumnFiltered();

ProductController->catalogAction(object(Request), 20, 0, 'price', 'desc')in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php (line 151)

        $this->dispatcher->dispatch(KernelEvents::CONTROLLER_ARGUMENTS, $event);

        $controller = $event->getController();

        $arguments = $event->getArguments();

        // call controller

        $response = \call_user_func_array($controller, $arguments);

        // view

        if (!$response instanceof Response) {

            $event = new GetResponseForControllerResultEvent($this, $request, $type, $response);

            $this->dispatcher->dispatch(KernelEvents::VIEW, $event);

HttpKernel->handleRaw(object(Request), 1)in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php (line 68)

    public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true)

    {

        $request->headers->set('X-Php-Ob-Level', ob_get_level());

        try {

            return $this->handleRaw($request, $type);

        } catch (\Exception $e) {

            if ($e instanceof RequestExceptionInterface) {

                $e = new BadRequestHttpException($e->getMessage(), $e);

            }

            if (false === $catch) {

HttpKernel->handle(object(Request), 1, false)in vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php (line 200)

        $this->boot();

        ++$this->requestStackSize;

        $this->resetServices = true;

        try {

            return $this->getHttpKernel()->handle($request, $type, $catch);

        } finally {

            --$this->requestStackSize;

        }

    }

Kernel->handle(object(Request), 1, false)in glwm7d6ai1bk4rxl/index.php (line 86)

$request = Request::createFromGlobals();

Request::setTrustedProxies([], Request::HEADER_X_FORWARDED_ALL);

try {

    require_once __DIR__.'/../autoload.php';

    $response = $kernel->handle($request, HttpKernelInterface::MASTER_REQUEST, false);

    $response->send();

    $kernel->terminate($request, $response);

} catch (NotFoundHttpException $exception) {

    define('ADMIN_LEGACY_CONTEXT', true);

    // correct Apache charset (except if it's too late)

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

  • 3 weeks later...

Since the module is broken you should ask for support from its developers.

Meanwhile if you don't have BO access to uninstall it, go by FTP/SSH to the modules directory and rename that module e.g from module_name to module_name.bad.

Once done you'll get the site working again.

If not check if the module comes with an override dir then rename all those files from the PS override dir, if they exist there too and are not used by other modules.

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...