Jump to content


Photo

[Solved] Django+Python on Tommy


  • Please log in to reply
12 replies to this topic

#1 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 20 March 2020 - 02:19 PM

Hi, I tried to deploy a site using Django+Python on Tommy for a subdomain, but it shows:

"Not Found

The requested URL was not found on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request."

 

I updated the .htaccess and wsgi following the " Getting started with Django 1.11", but it seems not work. Is it becuase that the Django version is 2.X now? Thanks!

 

 



#2 Krydos

Krydos

    Rank X Member

  • Root Admin
  • 19,663 posts
  • Gender:Male

Posted 23 March 2020 - 04:15 PM

Is this the guide you followed? https://wiki.helionet.org/Django



#3 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 27 March 2020 - 08:44 AM

Yes, I followed this guide, but I use the directory structure like below, becuase I want to set the site for a subdomain.

../hello/
├── db.sqlite3
├── hello/
│   ├── __init__.py
│   ├── __pycache__/
│   │   ├── ...
│   ├── settings.py
│   ├── urls.py
│   └── wsgi.py
└── manage.py

 



#4 Krydos

Krydos

    Rank X Member

  • Root Admin
  • 19,663 posts
  • Gender:Male

Posted 28 March 2020 - 02:03 AM

What is the url to the django site?



#5 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 28 March 2020 - 08:21 AM

It's aistocks.sopython.heliohost.org



#6 sohamb03

sohamb03

    Rank IX Member

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 906 posts
  • Gender:Male
  • Location:India
  • Interests:Web Designing

Posted 28 March 2020 - 08:34 AM

I'm getting a 500 Internal Server Error rather than a 404.

Sayan Bhattacharyya


#7 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 28 March 2020 - 01:14 PM

yes, I found there is another .htaccess in aiStocks/aiStocks, so I deleted it, then the error changed from 404 to 500. I don't know the 500 error is caused  by error in .htassecc or in dispatch.wsgi.

 

 



#8 Krydos

Krydos

    Rank X Member

  • Root Admin
  • 19,663 posts
  • Gender:Male

Posted 28 March 2020 - 09:48 PM

The 500 error is due to an infinite redirect. This usually indicates an error in your .htaccess. I wonder if it's related to you using aiStocks sometimes and aistocks in other places? Linux is case sensitive.



#9 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 29 March 2020 - 01:37 PM

Oh, yes, this is the reason. I use aistocks in all places now, then it changes back to the 404 error  :-(



#10 Krydos

Krydos

    Rank X Member

  • Root Admin
  • 19,663 posts
  • Gender:Male

Posted 30 March 2020 - 01:20 AM

You'll need to edit your subdomain to point at aistocks (lowercase) too.



#11 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 30 March 2020 - 07:57 AM

Thanks for pointing this. I have changed the doc root to aistocks, now the error becomes 500



#12 Krydos

Krydos

    Rank X Member

  • Root Admin
  • 19,663 posts
  • Gender:Male

Posted 31 March 2020 - 02:13 AM

Well, now that we fixed your .htaccess and uppercase/lowercase stuff you have a whole heap of errors:
[Tue Mar 31 02:10:15.809029 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] mod_wsgi (pid=86751): Failed to exec Python script file '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'.
[Tue Mar 31 02:10:15.809138 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] mod_wsgi (pid=86751): Exception occurred processing WSGI script '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'.
[Tue Mar 31 02:10:15.813632 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] Traceback (most recent call last):
[Tue Mar 31 02:10:15.813820 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi", line 7, in <module>
[Tue Mar 31 02:10:15.813845 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     _application = django.core.handlers.wsgi.WSGIHandler()
[Tue Mar 31 02:10:15.813870 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/wsgi.py", line 136, in __init__
[Tue Mar 31 02:10:15.813887 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     self.load_middleware()
[Tue Mar 31 02:10:15.813910 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/base.py", line 34, in load_middleware
[Tue Mar 31 02:10:15.813926 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     middleware = import_string(middleware_path)
[Tue Mar 31 02:10:15.813947 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/utils/module_loading.py", line 17, in import_string
[Tue Mar 31 02:10:15.813963 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     module = import_module(module_path)
[Tue Mar 31 02:10:15.813984 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/importlib/__init__.py", line 127, in import_module
[Tue Mar 31 02:10:15.814000 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     return _bootstrap._gcd_import(name[level:], package, level)
[Tue Mar 31 02:10:15.814021 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
[Tue Mar 31 02:10:15.814046 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 983, in _find_and_load
[Tue Mar 31 02:10:15.814072 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
[Tue Mar 31 02:10:15.814097 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
[Tue Mar 31 02:10:15.814121 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap_external>", line 728, in exec_module
[Tue Mar 31 02:10:15.814157 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
[Tue Mar 31 02:10:15.814183 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/middleware.py", line 4, in <module>
[Tue Mar 31 02:10:15.814199 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     from django.contrib.auth.backends import RemoteUserBackend
[Tue Mar 31 02:10:15.814221 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/backends.py", line 2, in <module>
[Tue Mar 31 02:10:15.814237 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     from django.contrib.auth.models import Permission
[Tue Mar 31 02:10:15.814259 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/models.py", line 2, in <module>
[Tue Mar 31 02:10:15.814353 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager
[Tue Mar 31 02:10:15.814388 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/base_user.py", line 47, in <module>
[Tue Mar 31 02:10:15.814404 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     class AbstractBaseUser(models.Model):
[Tue Mar 31 02:10:15.814426 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/db/models/base.py", line 87, in __new__
[Tue Mar 31 02:10:15.814442 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     app_config = apps.get_containing_app_config(module)
[Tue Mar 31 02:10:15.814464 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 249, in get_containing_app_config
[Tue Mar 31 02:10:15.814480 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     self.check_apps_ready()
[Tue Mar 31 02:10:15.814502 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 132, in check_apps_ready
[Tue Mar 31 02:10:15.814518 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     raise AppRegistryNotReady("Apps aren't loaded yet.")
[Tue Mar 31 02:10:15.814574 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet.
[Tue Mar 31 02:10:15.818340 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] mod_wsgi (pid=86751): Failed to exec Python script file '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'.
[Tue Mar 31 02:10:15.818419 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] mod_wsgi (pid=86751): Exception occurred processing WSGI script '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'.
[Tue Mar 31 02:10:15.818883 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] Traceback (most recent call last):
[Tue Mar 31 02:10:15.819012 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi", line 7, in <module>
[Tue Mar 31 02:10:15.819033 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     _application = django.core.handlers.wsgi.WSGIHandler()
[Tue Mar 31 02:10:15.819059 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/wsgi.py", line 136, in __init__
[Tue Mar 31 02:10:15.819075 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     self.load_middleware()
[Tue Mar 31 02:10:15.819098 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/base.py", line 34, in load_middleware
[Tue Mar 31 02:10:15.819127 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     middleware = import_string(middleware_path)
[Tue Mar 31 02:10:15.819151 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/utils/module_loading.py", line 17, in import_string
[Tue Mar 31 02:10:15.819169 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     module = import_module(module_path)
[Tue Mar 31 02:10:15.819194 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/importlib/__init__.py", line 127, in import_module
[Tue Mar 31 02:10:15.819210 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     return _bootstrap._gcd_import(name[level:], package, level)
[Tue Mar 31 02:10:15.819232 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
[Tue Mar 31 02:10:15.819257 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 983, in _find_and_load
[Tue Mar 31 02:10:15.819281 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
[Tue Mar 31 02:10:15.819305 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
[Tue Mar 31 02:10:15.819333 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap_external>", line 728, in exec_module
[Tue Mar 31 02:10:15.819358 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
[Tue Mar 31 02:10:15.819391 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/middleware.py", line 4, in <module>
[Tue Mar 31 02:10:15.819415 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     from django.contrib.auth.backends import RemoteUserBackend
[Tue Mar 31 02:10:15.819451 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/backends.py", line 2, in <module>
[Tue Mar 31 02:10:15.819471 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     from django.contrib.auth.models import Permission
[Tue Mar 31 02:10:15.819494 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/models.py", line 2, in <module>
[Tue Mar 31 02:10:15.819510 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager
[Tue Mar 31 02:10:15.819532 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/base_user.py", line 47, in <module>
[Tue Mar 31 02:10:15.819548 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     class AbstractBaseUser(models.Model):
[Tue Mar 31 02:10:15.819570 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/db/models/base.py", line 87, in __new__
[Tue Mar 31 02:10:15.819586 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     app_config = apps.get_containing_app_config(module)
[Tue Mar 31 02:10:15.819609 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 249, in get_containing_app_config
[Tue Mar 31 02:10:15.819629 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     self.check_apps_ready()
[Tue Mar 31 02:10:15.819652 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 132, in check_apps_ready
[Tue Mar 31 02:10:15.819668 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761]     raise AppRegistryNotReady("Apps aren't loaded yet.")
[Tue Mar 31 02:10:15.819717 2020] [wsgi:error] [pid 86751] [client 65.19.143.5:50761] django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet.
[Tue Mar 31 02:10:16.767114 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] mod_wsgi (pid=46696): Failed to exec Python script file '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'., referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.767228 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] mod_wsgi (pid=46696): Exception occurred processing WSGI script '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'., referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.771944 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] Traceback (most recent call last):, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772103 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi", line 7, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772125 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     _application = django.core.handlers.wsgi.WSGIHandler(), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772151 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/wsgi.py", line 136, in __init__, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772168 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     self.load_middleware(), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772191 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/base.py", line 34, in load_middleware, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772207 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     middleware = import_string(middleware_path), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772230 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/utils/module_loading.py", line 17, in import_string, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772246 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     module = import_module(module_path), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772267 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/importlib/__init__.py", line 127, in import_module, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772283 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     return _bootstrap._gcd_import(name[level:], package, level), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772305 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 1006, in _gcd_import, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772330 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 983, in _find_and_load, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772358 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772398 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 677, in _load_unlocked, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772424 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap_external>", line 728, in exec_module, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772448 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772472 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/middleware.py", line 4, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772488 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     from django.contrib.auth.backends import RemoteUserBackend, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772510 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/backends.py", line 2, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772526 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     from django.contrib.auth.models import Permission, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772548 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/models.py", line 2, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772563 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772585 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/base_user.py", line 47, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772600 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     class AbstractBaseUser(models.Model):, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772623 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/db/models/base.py", line 87, in __new__, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772646 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     app_config = apps.get_containing_app_config(module), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772668 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 249, in get_containing_app_config, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772684 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     self.check_apps_ready(), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772706 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 132, in check_apps_ready, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772722 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     raise AppRegistryNotReady("Apps aren't loaded yet."), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.772805 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet., referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777121 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] mod_wsgi (pid=46696): Failed to exec Python script file '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'., referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777228 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] mod_wsgi (pid=46696): Exception occurred processing WSGI script '/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi'., referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777689 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] Traceback (most recent call last):, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777852 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/home/sopython/public_html/aistocks/aistocks/dispatch.wsgi", line 7, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777876 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     _application = django.core.handlers.wsgi.WSGIHandler(), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777902 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/wsgi.py", line 136, in __init__, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777919 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     self.load_middleware(), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777942 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/core/handlers/base.py", line 34, in load_middleware, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777959 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     middleware = import_string(middleware_path), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777981 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/utils/module_loading.py", line 17, in import_string, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.777997 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     module = import_module(module_path), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778019 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/importlib/__init__.py", line 127, in import_module, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778035 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     return _bootstrap._gcd_import(name[level:], package, level), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778057 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 1006, in _gcd_import, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778091 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 983, in _find_and_load, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778118 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778142 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 677, in _load_unlocked, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778167 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap_external>", line 728, in exec_module, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778191 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778217 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/middleware.py", line 4, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778253 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     from django.contrib.auth.backends import RemoteUserBackend, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778299 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/backends.py", line 2, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778326 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     from django.contrib.auth.models import Permission, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778354 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/models.py", line 2, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778371 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778393 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/contrib/auth/base_user.py", line 47, in <module>, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778409 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     class AbstractBaseUser(models.Model):, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778431 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/db/models/base.py", line 87, in __new__, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778447 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     app_config = apps.get_containing_app_config(module), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778469 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 249, in get_containing_app_config, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778489 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     self.check_apps_ready(), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778513 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]   File "/usr/local/python3.7/lib/python3.7/site-packages/django/apps/registry.py", line 132, in check_apps_ready, referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778529 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762]     raise AppRegistryNotReady("Apps aren't loaded yet."), referer: http://aistocks.sopython.heliohost.org/
[Tue Mar 31 02:10:16.778572 2020] [wsgi:error] [pid 46696] [client 65.19.143.5:50762] django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet., referer: http://aistocks.sopython.heliohost.org/


#13 sopython

sopython

    Rank I Member

  • Members
  • Pip
  • 15 posts

Posted 31 March 2020 - 09:00 AM

Thanks for the detailed information. I updated the dispatch.wsgi. Now it works. Thank you so much!






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users