콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
1 회신
7198 화면

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.

 

아바타
취소
베스트 답변

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.