📜 ⬆️ ⬇️

Sentry - monitoring errors in Django

How do you monitor errors in your Django project?

Django has a standard error monitoring mechanism that sends an error notification with detailed information to the specified email. The thing is undoubtedly useful. The letter contains all information about the error: the name of the error, where it originated, where the transition to the page came from, etc. But there is one big drawback: when a project is large and there are quite a few mistakes, the number of error notification letters becomes such that most of them are simply ignored.

We used the same option until we discovered Sentry.
image

Sentry is a Django embedded application for online error monitoring. The user interface is a dashboard with a list of errors and the ability to perform various actions on them.
')
Key features:


Installation


1. So, install the module with the easy_install django-sentry .

2. Next, add sentry to your application settings file (settings.py):

INSTALLED_APPS = (
...
'indexer',
'paging',
'sentry',
'sentry.client',
...
)


3. Now set the url for Sentry in your urls.py file:

urlpatterns = patterns('',
(r'^sentry/', include('sentry.urls')),
)


4. To complete, run python manage.py syncdb to create the necessary tables. All is ready.

It is also recommended to add the option TEMPLATE_DEBUG=True to your settings file. This will allow Sentry to get debug information about errors.

Related Links

github.com/dcramer/django-sentry

Source: https://habr.com/ru/post/111283/


All Articles