Skip to content

Commit

Permalink
Merge pull request #1545 from maykinmedia/swr/bump-sentry-sdk
Browse files Browse the repository at this point in the history
Bump Sentry to latest version
  • Loading branch information
alextreme authored Jan 9, 2025
2 parents 27bc304 + 31045d1 commit 4b86009
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 5 deletions.
2 changes: 1 addition & 1 deletion requirements/base.in
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ djangorestframework-camel-case

# WSGI servers & monitoring - production oriented
uwsgi
sentry-sdk # error monitoring
sentry-sdk[django] # error monitoring
elastic-apm # Elastic APM integration

beautifulsoup4
Expand Down
3 changes: 2 additions & 1 deletion requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ django==4.2.16
# mozilla-django-oidc
# mozilla-django-oidc-db
# notifications-api-common
# sentry-sdk
# zgw-consumers
# zgw-consumers-oas
django-admin-index==3.1.0
Expand Down Expand Up @@ -523,7 +524,7 @@ requests==2.31.0
# messagebird
# mozilla-django-oidc
# zgw-consumers
sentry-sdk==1.38.0
sentry-sdk[django]==2.19.2
# via -r requirements/base.in
simplejson==3.19.2
# via mail-parser
Expand Down
4 changes: 3 additions & 1 deletion requirements/ci.txt
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,7 @@ django==4.2.16
# mozilla-django-oidc
# mozilla-django-oidc-db
# notifications-api-common
# sentry-sdk
# zgw-consumers
# zgw-consumers-oas
django-admin-index==3.1.0
Expand Down Expand Up @@ -992,10 +993,11 @@ requests==2.31.0
# zgw-consumers
requests-mock==1.12.1
# via -r requirements/test-tools.in
sentry-sdk==1.38.0
sentry-sdk[django]==2.19.2
# via
# -c requirements/base.txt
# -r requirements/base.txt
# sentry-sdk
simplejson==3.19.2
# via
# -c requirements/base.txt
Expand Down
4 changes: 3 additions & 1 deletion requirements/dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,7 @@ django==4.2.16
# mozilla-django-oidc
# mozilla-django-oidc-db
# notifications-api-common
# sentry-sdk
# zgw-consumers
# zgw-consumers-oas
django-admin-index==3.1.0
Expand Down Expand Up @@ -1148,10 +1149,11 @@ requests-mock==1.12.1
# -r requirements/ci.txt
roundrobin==0.0.4
# via locust
sentry-sdk==1.38.0
sentry-sdk[django]==2.19.2
# via
# -c requirements/ci.txt
# -r requirements/ci.txt
# sentry-sdk
simplejson==3.19.2
# via
# -c requirements/ci.txt
Expand Down
6 changes: 6 additions & 0 deletions src/open_inwoner/celery.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,9 @@ def worker_shutdown(**_):


app.steps["worker"].add(LivenessProbe)


@app.task
def trigger_exception():
"""Trigger an exception for debugging purposes."""
return 1 / 0
4 changes: 3 additions & 1 deletion src/open_inwoner/conf/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ def get_sentry_integrations() -> list:
try:
from sentry_sdk.integrations import celery
except DidNotEnable: # happens if the celery import fails by the integration
pass
logger.warning(
"Unable to initialize Sentry with Celery integration due to failing import"
)
else:
extra.append(celery.CeleryIntegration())

Expand Down

0 comments on commit 4b86009

Please sign in to comment.