Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
1 Vastaa
7190 Näkymät

My logs files are pregnant with a template error on every page load.

The root cause line of the traceback says :

"QWebException: foreach enumerator 'languages' is not defined while rendering template 'website.layout'"

I posted the complete traceback of the error here : https://gist.github.com/martinhbramwell/908b7f0787b8e8b93955

The short version of my question is :  is this a known error? where's the fix?

The long version  :  website.layout seems to be subclassed all over the place. where is the root template? how do I track down which subclass template has the root cause?

I deliberately changed the language of the website (and my browser), but the language did not change. and the error persists.

 

Avatar
Hylkää
Paras vastaus

Please go to the following file addons/website/views/website_templates.xml on line no. 181

change:  <li t-foreach="website.get_languages()" t-as="lg">

instead of: <li t-foreach="languages" t-as="lg">

Avatar
Hylkää
Tekijä

That worked, but so did getting the very latest nightly. Thanks in any case.