Hello, pythonanywhere team. I think there may be a problem with my account. For my Django project, it is ok to run locally (or at least the local env will alert me when an error is encountered). But when online, I kept getting error: 502-backend error, and there was no more useful information in the error log and server log that could point me to the error, Even if I set debug=True.
The error log:
[ERROR 2021-02-17 11:23:09,045 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,045 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,045 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,045 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,044 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,044 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,044 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,044 user_wsgi_wrapper.py:165] [ERROR 2021-02-17 11:23:09,044 user_wsgi_wrapper.py:165] Error running WSGI application
repeats countless times;
the server log:
2021-02-17 11:23:09 File "/bin/user_wsgi_wrapper.py", line 165, in write
2021-02-17 11:23:09 self.logger.error(line)
2021-02-17 11:23:09 File "/usr/lib/python3.8/logging/__init__.py", line 1463, in error
2021-02-17 11:23:09 self._log(ERROR, msg, args, **kwargs)
2021-02-17 11:23:09 File "/usr/lib/python3.8/logging/__init__.py", line 1577, in _log
2021-02-17 11:23:09 self.handle(record)
2021-02-17 11:23:09 File "/usr/lib/python3.8/logging/__init__.py", line 1587, in handle
2021-02-17 11:23:09 self.callHandlers(record)
2021-02-17 11:23:09 File "/usr/lib/python3.8/logging/__init__.py", line 1649, in callHandlers
2021-02-17 11:23:09 hdlr.handle(record)
2021-02-17 11:23:09 File "/usr/lib/python3.8/logging/__init__.py", line 950, in handle
2021-02-17 11:23:09 self.emit(record)
2021-02-17 11:23:09 File "/bin/user_wsgi_wrapper.py", line 110, in emit
2021-02-17 11:23:09 format_with_millis(datetime.now()), self.format(record)
2021-02-17 11:23:09 File "/bin/user_wsgi_wrapper.py", line 96, in format_with_millis
2021-02-17 11:23:09 return "{:%Y-%m-%d %H:%M:%S},{:03d}".format(
2021-02-17 11:23:09 RecursionError: maximum recursion depth exceeded while calling a Python object
Same repeated countless times.
At first I thought it was a problem with my code. I checked my code for a long time but found nothing. Until I ran a very simple code, but this error also appeared, then I realize that it should not be the code error.
I started to check my account settings, and there seemed to be no problems, but I found that django commands were no longer working. When I run python manage.py (without parameters), it will remind me of the available parameters; but when I run python manage.py makemigrations/createsuperuser... with any parameters, it shows the parameters are incorrect.
I have asked about the system environment problem before, and I tried to solve it myself before that. I don’t know if I used the wrong command, which caused problems(I'm sorry, I might be the bad guy). I have never used Linux before. So I have no idea about the situation.
Thank you in advance.