[Django]-Twisted server crashes unexpectedly while running django

1👍

There is no 499 http code in rfc. Nginx defines 499 code itself.

When a client sent a request, and closed the connection without waiting for
the response, a 499 code occurs. If there’re a lot of 499s in your
access_log, it’s mostly caused by the slow back-ends (too slow for your
users to wait). You may have to optimize your website performance.

http://forum.nginx.org/read.php?2,213789,213794#msg-213794

1👍

  • you say the problem is from a client hitting a particular url (reproducible?)
  • since it works for you with gunicorn but not django-on-twisted, either the script is not working properly or twisted.web2 is the issue.

please try $ sh init.sh yourdjangoproject stand.

you can also try to modify run.py to catch SystemExit:

import pdb
try:
   # __main__ stuff here.
except (KeyboardInterrupt, SystemExit):
   pdb.set_trace()
👤dnozay

Leave a comment