Re: Django graceful database errors

2017-06-07 Thread Damian Myerscough
s/damian/env36/lib/python3.6/site-packages/django/db/backends/base/base.py" in connect 189. self.connection = self.get_new_connection(conn_params) File "/Users/damian/env36/lib/python3.6/site-packages/django/db/backends/mysql/base.py" in get_new_connection 274.

Django graceful database errors

2017-06-07 Thread Damian Myerscough
Hello, I have setup a Django project that is being served via Nginx + gunicorn, however, I would like to handle graceful database failures. For example, if the ORM cannot query the database I would like to return a custom error message. ==> gunicorn.log <== [2017-06-07 06:06:01 +] [13] [DE