Odoo Help


This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


V8 Website builder : How to debug a template error?

on 6/19/14, 5:39 AM 2,062 views

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.


Ronak Baxi (rba)
On 6/19/14, 7:47 AM

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

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

on 6/20/14, 6:29 PM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)


Asked: 6/19/14, 5:39 AM
Seen: 2062 times
Last updated: 3/16/15, 8:10 AM