Jump to content

Cannot load store or access BO after enable a theme


Recommended Posts

Hello,

I'm using Prestashop ver. 1.7.4.1.  I've uploaded a theme through ftp and enabled it in the BO, after that my store won't load neither I can access to BO, it would give me a 500 error.  I've enabled the debug mode by editing the config/defines.inc.php file and this is what it shows now:

Fatal error: Uncaught exception 'Symfony\Component\Yaml\Exception\ParseException' with message 'You cannot define a mapping item when in a sequence at line 2 (near "path: assets/css/custom.css")' in /home/xpto/public_html/Loja/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php:253 Stack trace: #0 /home/xpto/public_html/Loja/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php(504): Symfony\Component\Yaml\Parser->doParse('- id: custom-li...', 0) #1 /home/xpto/public_html/Loja/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php(365): Symfony\Component\Yaml\Parser->parseBlock(10, '- id: custom-li...', 0) #2 /home/xpto/public_html/Loja/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php(141): Symfony\Component\Yaml\Parser->doParse('parent: classic...', 0) #3 /home/xpto/public_html/Loja/src/Core/Addon/Theme/ThemeRepository.php(141): Symfony\Component\Yaml\Parser->parse('parent: classic...') #4 /home/xpto/public_html/Loja/src/Core/Addon/Theme/ThemeRepository.php(65): PrestaShop\Pr in /home/xpto/public_html/Loja/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php on line 253

 

Any tips on how to get around this or is there any configuration file where I could set which theme to use?

 

Link to comment
Share on other sites

  • 2 years later...
  • 3 months later...

I have the same problem too.

Upgraded from PS1.7.4.2 to PS1.7.7.2, then I enabled a template ad both back office and front office stopped working:

Cita

Fatal error: Uncaught Symfony\Component\Yaml\Exception\ParseException: A YAML file cannot contain tabs as indentation at line 69 (near " - ps_shoppingcart"). in /var/www/vhosts/miosito.eu/httpdocs/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php:202 Stack trace: #0 /var/www/vhosts/miosito.eu/httpdocs/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php(142): Symfony\Component\Yaml\Parser->doParse(Array, 0) #1 /var/www/vhosts/miosito.eu/httpdocs/src/Core/Addon/Theme/ThemeRepository.php(151): Symfony\Component\Yaml\Parser->parse('parent: classic...') #2 /var/www/vhosts/miosito.eu/httpdocs/src/Core/Addon/Theme/ThemeRepository.php(66): PrestaShop\PrestaShop\Core\Addon\Theme\ThemeRepository->getConfigFromFile('/var/www/vhosts...') #3 /var/www/vhosts/miosito.eu/httpdocs/classes/shop/Shop.php(491): PrestaShop\PrestaShop\Core\Addon\Theme\ThemeRepository->getInstanceByName('dottor') #4 /var/www/vhosts/miosito.eu/httpdocs/classes/shop/Shop.php(133): ShopCore->setTheme() #5 /var/www/vhosts/miosito.eu/httpdocs/classes/sho in /var/www/vhosts/miosito.eu/httpdocs/vendor/symfony/symfony/src/Symfony/Component/Yaml/Parser.php on line 202

 

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

Hi DARK,

The problem you are facing is not exactly the same as mine, but here's how i resolved it.

You should have a .json file in your /config/themes/your-template (someting like shop1.json).

If the file is there, verifiy if the informations in it are good; I would even say to add the "_old" annotation to your old templates in this folder.

If not, you must recover it from your template's folder.

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