https://github.com/danielwelch/django-q-sentry
Bringing Sentry error tracking to Django Q
https://github.com/danielwelch/django-q-sentry
django django-q sentry
Last synced: 15 days ago
JSON representation
Bringing Sentry error tracking to Django Q
- Host: GitHub
- URL: https://github.com/danielwelch/django-q-sentry
- Owner: danielwelch
- License: mit
- Created: 2017-03-31T01:58:08.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2025-03-17T08:27:54.000Z (7 months ago)
- Last Synced: 2025-07-14T10:26:23.293Z (3 months ago)
- Topics: django, django-q, sentry
- Language: Python
- Homepage:
- Size: 22.5 KB
- Stars: 10
- Watchers: 3
- Forks: 7
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# django-q-sentry
A [Django Q](https://github.com/Koed00/django-q/) Error Reporter plugin adding Sentry support.
# Before version 0.1.3 sentry raven was a dependency. After 0.1.3 sentry-sdk used as raven is being deprecated.# Upgraded to sentry version 2.0.0 and higher.
# Added check to see if sentry already instantiated.### Installation
This plugin is intended to be included with Django Q as [setuptools extra](https://setuptools.readthedocs.io/en/latest/setuptools.html#declaring-extras-optional-features-with-their-own-dependencies).
`$ pip install django-q[sentry]`
Or add `django-q[sentry]` to `requirements.txt`.
> This plugin requires Django Q version 0.8.1 or greater.
### Usage
Configure Sentry via the Django Q `Q_CLUSTER` dictionary in your Django project's `settings.py`. It is important that the `sentry` key be set in the `error_reporter` dictionary, as this name aligns with the project's entry point for this plugin. The only required configuration entry is your Sentry DSN.
If sentry is init has been called in your code already, we will use Django's existing Sentry configuration.
```python
Q_CLUSTER = {
'error_reporter': {
'sentry': {
'dsn': 'https://******@sentry.io/'
}
}
}
```
Please check the [python sentry client configuration docs](https://docs.sentry.io/platforms/python/) for more options. Additional key-value pairs defined in `Q_CLUSTER['error_reporter']['sentry']` are passed directly as kwargs to instantiation of [`sentry.sentry_sdk`](https://docs.sentry.io/platforms/python/configuration/options/).