<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri","sans-serif";
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri","sans-serif";
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=FR-CA link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hello guys,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal> <span lang=EN-CA>I have an issue with Horizon dashboard following an update from Grizzly to Havana.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-CA>In Apache error logs, I have the following:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] DeprecationWarning: Translations in the project directory aren't supported anymore. Use the LOCALE_PATHS setting instead.['horizon.example.com', 'localhost']<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] Internal Server Error: /dashboard/admin/<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] Traceback (most recent call last):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] File "/usr/lib/python2.6/site-packages/django/core/handlers/base.py", line 89, in get_response<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] response = middleware_method(request)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] File "/usr/lib/python2.6/site-packages/django/middleware/common.py", line 55, in process_request<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] host = request.get_host()<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] File "/usr/lib/python2.6/site-packages/django/http/__init__.py", line 224, in get_host<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] "Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS): %s" % host)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>[Tue Oct 22 18:48:01 2013] [error] SuspiciousOperation: Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS): stv-lab-ctrl02.ubisoft.org<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-CA>And if I comment out that part:<o:p></o:p></span></p><p class=MsoNormal>--- a/django/http/__init__.py<o:p></o:p></p><p class=MsoNormal>+++ b/django/http/__init__.py<o:p></o:p></p><p class=MsoNormal><span lang=EN-CA>@@ -214,13 +214,13 @@ class HttpRequest(object):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA> server_port = str(self.META['SERVER_PORT'])<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA> if server_port != (self.is_secure() and '443' or '80'):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA> host = '%s:%s' % (host, server_port)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>-<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>+<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA> allowed_hosts = ['*'] if settings.DEBUG else settings.ALLOWED_HOSTS<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>- if validate_host(host, allowed_hosts):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>- return host<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>- else:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>- raise SuspiciousOperation(<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>- "Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS): %s" % host)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>+# if validate_host(host, allowed_hosts):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>+# return host<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>+# else:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>+# raise SuspiciousOperation(<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA>+# "Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS): %s" % host)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-CA> def get_full_path(self):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA> # RFC 3986 requires query string arguments to be in the ASCII range.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-CA>It seems to be “working” … Does anybody encountered this error message or issues with the dashboard following the upgrade from Grizzly to Havana?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-CA>Thank you very much,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-CA>Dave<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-CA><o:p> </o:p></span></p></div></body></html>