Loading

Django Error nasirhm

  1. Environment:
  2.  
  3.  
  4. Request Method: GET
  5. Request URL: http://hp-shraddhaag.127.0.0.1.nip.io/
  6.  
  7. Django Version: 2.0
  8. Python Version: 3.6.8
  9. Installed Applications:
  10. ['django.contrib.auth',
  11.  'mozilla_django_oidc',
  12.  'django.contrib.contenttypes',
  13.  'django.contrib.sessions',
  14.  'django.contrib.messages',
  15.  'django.contrib.staticfiles',
  16.  'django.contrib.admin',
  17.  'django.contrib.humanize',
  18.  'django_extensions',
  19.  'crispy_forms',
  20.  'haystack',
  21.  'happinesspackets.messaging',
  22.  'djcelery_email',
  23.  'ckeditor',
  24.  'debug_toolbar']
  25. Installed Middleware:
  26. ['django.contrib.sessions.middleware.SessionMiddleware',
  27.  'django.contrib.auth.middleware.AuthenticationMiddleware',
  28.  'happinesspackets.utils.middleware.SetRemoteAddrFromForwardedFor',
  29.  'dogslow.WatchdogMiddleware',
  30.  'django.middleware.common.CommonMiddleware',
  31.  'django.middleware.csrf.CsrfViewMiddleware',
  32.  'django.contrib.messages.middleware.MessageMiddleware',
  33.  'debug_toolbar.middleware.DebugToolbarMiddleware']
  34.  
  35.  
  36.  
  37. Traceback:
  38.  
  39. File "/usr/local/lib/python3.6/site-packages/django/core/handlers/exception.py" in inner
  40.   35.             response = get_response(request)
  41.  
  42. File "/usr/local/lib/python3.6/site-packages/django/utils/deprecation.py" in __call__
  43.   93.             response = self.process_request(request)
  44.  
  45. File "/usr/local/lib/python3.6/site-packages/django/middleware/common.py" in process_request
  46.   55.         host = request.get_host()
  47.  
  48. File "/usr/local/lib/python3.6/site-packages/django/http/request.py" in get_host
  49.   105.             raise DisallowedHost(msg)
  50.  
  51. Exception Type: DisallowedHost at /
  52. Exception Value: Invalid HTTP_HOST header: 'hp-shraddhaag.127.0.0.1.nip.io'. You may need to add 'hp-shraddhaag.127.0.0.1.nip.io' to ALLOWED_HOSTS.