<class 'django.core.exceptions.DisallowedHost'>
Python 2.7.6: /usr/bin/python
Fri Apr 20 07:22:30 2018

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.

 /home/ywcbelting/ywcbelting.com/fcgi.py in run(self=<fcgi.Request object>)
    578         """Runs the handler, flushes the streams, and ends the request."""
    579         try:
=>  580             protocolStatus, appStatus = self.server.handler(self)
    581         except:
    582             traceback.print_exc(file=self.stderr)
protocolStatus undefined, appStatus undefined, self = <fcgi.Request object>, self.server = <fcgi.WSGIServer object>, self.server.handler = <bound method WSGIServer.handler of <fcgi.WSGIServer object>>
 /home/ywcbelting/ywcbelting.com/fcgi.py in handler(self=<fcgi.WSGIServer object>, req=<fcgi.Request object>)
   1264         try:
   1265             try:
=> 1266                 result = self.application(environ, start_response)
   1267                 try:
   1268                     for data in result:
result = None, self = <fcgi.WSGIServer object>, self.application = <django.core.handlers.wsgi.WSGIHandler object>, environ = {'DH_USER': 'ywcbelting', 'DOCUMENT_ROOT': '/home/ywcbelting/ywcbelting.com', 'GATEWAY_INTERFACE': 'CGI/1.1', 'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'HTTP_ACCEPT_ENCODING': 'x-gzip, gzip, deflate', 'HTTP_CONNECTION': 'close', 'HTTP_HOST': 'www.ywcbelting.com', 'HTTP_IF_MODIFIED_SINCE': 'Sat, 20 Jan 2018 16:39:19 GMT', 'HTTP_USER_AGENT': 'CCBot/2.0 (http://commoncrawl.org/faq/)', 'PATH': '/bin:/usr/bin:/sbin:/usr/sbin', ...}, start_response = <function start_response>
 /usr/lib/python2.7/dist-packages/django/core/handlers/wsgi.py in __call__(self=<django.core.handlers.wsgi.WSGIHandler object>, environ={'DH_USER': 'ywcbelting', 'DOCUMENT_ROOT': '/home/ywcbelting/ywcbelting.com', 'GATEWAY_INTERFACE': 'CGI/1.1', 'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'HTTP_ACCEPT_ENCODING': 'x-gzip, gzip, deflate', 'HTTP_CONNECTION': 'close', 'HTTP_HOST': 'www.ywcbelting.com', 'HTTP_IF_MODIFIED_SINCE': 'Sat, 20 Jan 2018 16:39:19 GMT', 'HTTP_USER_AGENT': 'CCBot/2.0 (http://commoncrawl.org/faq/)', 'PATH': '/bin:/usr/bin:/sbin:/usr/sbin', ...}, start_response=<function start_response>)
    204             response = http.HttpResponseBadRequest()
    205         else:
=>  206             response = self.get_response(request)
    207 
    208         response._handler_class = self.__class__
response undefined, self = <django.core.handlers.wsgi.WSGIHandler object>, self.get_response = <bound method WSGIHandler.get_response of <django.core.handlers.wsgi.WSGIHandler object>>, request = <WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>
 /usr/lib/python2.7/dist-packages/django/core/handlers/base.py in get_response(self=<django.core.handlers.wsgi.WSGIHandler object>, request=<WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>)
    183                         sender=self.__class__, request=request)
    184                 response = self.handle_uncaught_exception(request,
=>  185                         resolver, sys.exc_info())
    186 
    187         except SystemExit:
resolver = <RegexURLResolver 'myproject.urls' (None:None) ^/>, global sys = <module 'sys' (built-in)>, sys.exc_info = <built-in function exc_info>
 /usr/lib/python2.7/dist-packages/django/core/handlers/base.py in handle_uncaught_exception(self=<django.core.handlers.wsgi.WSGIHandler object>, request=<WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>, resolver=<RegexURLResolver 'myproject.urls' (None:None) ^/>, exc_info=(<type 'exceptions.ImportError'>, ImportError('No module named defaults',), <traceback object>))
    227 
    228         if settings.DEBUG:
=>  229             return debug.technical_500_response(request, *exc_info)
    230 
    231         # If Http500 handler is not installed, re-raise last exception
global debug = <module 'django.views.debug' from '/usr/lib/python2.7/dist-packages/django/views/debug.pyc'>, debug.technical_500_response = <function technical_500_response>, request = <WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>, exc_info = (<type 'exceptions.ImportError'>, ImportError('No module named defaults',), <traceback object>)
 /usr/lib/python2.7/dist-packages/django/views/debug.py in technical_500_response(request=<WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>, exc_type=<type 'exceptions.ImportError'>, exc_value=ImportError('No module named defaults',), tb=<traceback object>)
     67         return HttpResponseServerError(text, content_type='text/plain')
     68     else:
=>   69         html = reporter.get_traceback_html()
     70         return HttpResponseServerError(html, content_type='text/html')
     71 
html undefined, reporter = <django.views.debug.ExceptionReporter object>, reporter.get_traceback_html = <bound method ExceptionReporter.get_traceback_html of <django.views.debug.ExceptionReporter object>>
 /usr/lib/python2.7/dist-packages/django/views/debug.py in get_traceback_html(self=<django.views.debug.ExceptionReporter object>)
    322         t = Template(TECHNICAL_500_TEMPLATE, name='Technical 500 template')
    323         c = Context(self.get_traceback_data())
=>  324         return t.render(c)
    325 
    326     def get_traceback_text(self):
t = <django.template.base.Template object>, t.render = <bound method Template.render of <django.template.base.Template object>>, c = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in render(self=<django.template.base.Template object>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    138         context.render_context.push()
    139         try:
=>  140             return self._render(context)
    141         finally:
    142             context.render_context.pop()
self = <django.template.base.Template object>, self._render = <bound method Template._render of <django.template.base.Template object>>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in _render(self=<django.template.base.Template object>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    132 
    133     def _render(self, context):
=>  134         return self.nodelist.render(context)
    135 
    136     def render(self, context):
self = <django.template.base.Template object>, self.nodelist = [<Text Node: ' <!DOCTYPE html> <html la'>, <IfNo...> '>, <IfNode>, <Text Node: ' </body> </html> '>], self.nodelist.render = <bound method DebugNodeList.render of [<Text Nod... '>, <IfNode>, <Text Node: ' </body> </html> '>]>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in render(self=[<Text Node: ' <!DOCTYPE html> <html la'>, <IfNo...> '>, <IfNode>, <Text Node: ' </body> </html> '>], context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    838         for node in self:
    839             if isinstance(node, Node):
=>  840                 bit = self.render_node(node, context)
    841             else:
    842                 bit = node
bit = u'</pre>\n <table class="meta">\n', self = [<Text Node: ' <!DOCTYPE html> <html la'>, <IfNo...> '>, <IfNode>, <Text Node: ' </body> </html> '>], self.render_node = <bound method DebugNodeList.render_node of [<Tex... '>, <IfNode>, <Text Node: ' </body> </html> '>]>, node = <IfNode>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/debug.py in render_node(self=[<Text Node: ' <!DOCTYPE html> <html la'>, <IfNo...> '>, <IfNode>, <Text Node: ' </body> </html> '>], node=<IfNode>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
     76     def render_node(self, node, context):
     77         try:
=>   78             return node.render(context)
     79         except Exception as e:
     80             if not hasattr(e, 'django_template_source'):
node = <IfNode>, node.render = <bound method IfNode.render of <IfNode>>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/defaulttags.py in render(self=<IfNode>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    303 
    304             if match:
=>  305                 return nodelist.render(context)
    306 
    307         return ''
nodelist = [<Text Node: ' <tr> <th>Reque'>, <Vari...ute_uri|escape>, <Text Node: '</td> </tr> '>], nodelist.render = <bound method DebugNodeList.render of [<Text Nod...te_uri|escape>, <Text Node: '</td> </tr> '>]>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in render(self=[<Text Node: ' <tr> <th>Reque'>, <Vari...ute_uri|escape>, <Text Node: '</td> </tr> '>], context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    838         for node in self:
    839             if isinstance(node, Node):
=>  840                 bit = self.render_node(node, context)
    841             else:
    842                 bit = node
bit = u'</td>\n </tr>\n <tr>\n <th>Request URL:</th>\n <td>', self = [<Text Node: ' <tr> <th>Reque'>, <Vari...ute_uri|escape>, <Text Node: '</td> </tr> '>], self.render_node = <bound method DebugNodeList.render_node of [<Tex...te_uri|escape>, <Text Node: '</td> </tr> '>]>, node = <Variable Node: request.build_absolute_uri|escape>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/debug.py in render_node(self=[<Text Node: ' <tr> <th>Reque'>, <Vari...ute_uri|escape>, <Text Node: '</td> </tr> '>], node=<Variable Node: request.build_absolute_uri|escape>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
     76     def render_node(self, node, context):
     77         try:
=>   78             return node.render(context)
     79         except Exception as e:
     80             if not hasattr(e, 'django_template_source'):
node = <Variable Node: request.build_absolute_uri|escape>, node.render = <bound method DebugVariableNode.render of <Variable Node: request.build_absolute_uri|escape>>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/debug.py in render(self=<Variable Node: request.build_absolute_uri|escape>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
     86     def render(self, context):
     87         try:
=>   88             output = self.filter_expression.resolve(context)
     89             output = template_localtime(output, use_tz=context.use_tz)
     90             output = localize(output, use_l10n=context.use_l10n)
output undefined, self = <Variable Node: request.build_absolute_uri|escape>, self.filter_expression = <django.template.base.FilterExpression object>, self.filter_expression.resolve = <bound method FilterExpression.resolve of <django.template.base.FilterExpression object>>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in resolve(self=<django.template.base.FilterExpression object>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}], ignore_failures=False)
    583         if isinstance(self.var, Variable):
    584             try:
=>  585                 obj = self.var.resolve(context)
    586             except VariableDoesNotExist:
    587                 if ignore_failures:
obj undefined, self = <django.template.base.FilterExpression object>, self.var = <Variable: u'request.build_absolute_uri'>, self.var.resolve = <bound method Variable.resolve of <Variable: u'request.build_absolute_uri'>>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in resolve(self=<Variable: u'request.build_absolute_uri'>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    733         if self.lookups is not None:
    734             # We're dealing with a variable that needs to be resolved
=>  735             value = self._resolve_lookup(context)
    736         else:
    737             # We're dealing with a literal, so it's already been "resolved"
value undefined, self = <Variable: u'request.build_absolute_uri'>, self._resolve_lookup = <bound method Variable._resolve_lookup of <Variable: u'request.build_absolute_uri'>>, context = [{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}]
 /usr/lib/python2.7/dist-packages/django/template/base.py in _resolve_lookup(self=<Variable: u'request.build_absolute_uri'>, context=[{'False': False, 'None': None, 'True': True}, {...n': (1, 0)}>, u'template_does_not_exist': False}])
    787                     else:
    788                         try: # method call (assuming no args required)
=>  789                             current = current()
    790                         except TypeError: # arguments *were* required
    791                             # GOTCHA: This will also catch any TypeError
current = <bound method WSGIRequest.build_absolute_uri of ...i.url_scheme': 'http', 'wsgi.version': (1, 0)}>>
 /usr/lib/python2.7/dist-packages/django/http/request.py in build_absolute_uri(self=<WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>, location=u'/contact/')
    117         if not absolute_http_url_re.match(location):
    118             current_uri = '%s://%s%s' % ('https' if self.is_secure() else 'http',
=>  119                                          self.get_host(), self.path)
    120             location = urljoin(current_uri, location)
    121         return iri_to_uri(location)
self = <WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>, self.get_host = <bound method WSGIRequest.get_host of <WSGIReque...i.url_scheme': 'http', 'wsgi.version': (1, 0)}>>, self.path = u'/contact/'
 /usr/lib/python2.7/dist-packages/django/http/request.py in get_host(self=<WSGIRequest path:/contact/, GET:<QueryDict: {}>...gi.url_scheme': 'http', 'wsgi.version': (1, 0)}>)
     77             if domain:
     78                 msg += "You may need to add %r to ALLOWED_HOSTS." % domain
=>   79             raise DisallowedHost(msg)
     80 
     81     def get_full_path(self):
global DisallowedHost = <class 'django.core.exceptions.DisallowedHost'>, msg = u"Invalid HTTP_HOST header: 'www.ywcbelting.com'.Y...ed to add u'www.ywcbelting.com' to ALLOWED_HOSTS."

<class 'django.core.exceptions.DisallowedHost'>: Invalid HTTP_HOST header: 'www.ywcbelting.com'.You may need to add u'www.ywcbelting.com' to ALLOWED_HOSTS.
      args = (u"Invalid HTTP_HOST header: 'www.ywcbelting.com'.Y...ed to add u'www.ywcbelting.com' to ALLOWED_HOSTS.",)
      django_template_source = (<django.template.base.StringOrigin object>, (5821, 5860))
      message = u"Invalid HTTP_HOST header: 'www.ywcbelting.com'.Y...ed to add u'www.ywcbelting.com' to ALLOWED_HOSTS."