Skip to content

Commit

Permalink
Enable sentry logging integration
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisLovering committed Dec 11, 2023
1 parent f641746 commit 04319c6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pydis_site/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
https://docs.djangoproject.com/en/2.1/ref/settings/
"""

import logging
import os
import secrets
import sys
Expand All @@ -19,6 +20,7 @@

import environ
import sentry_sdk
from sentry_sdk.integrations.logging import LoggingIntegration
from sentry_sdk.integrations.django import DjangoIntegration

env = environ.Env(
Expand Down Expand Up @@ -50,7 +52,7 @@
if not STATIC_BUILD:
sentry_sdk.init(
dsn=env('SITE_DSN'),
integrations=[DjangoIntegration()],
integrations=[DjangoIntegration(), LoggingIntegration(level=logging.DEBUG, event_level=logging.ERROR)],
send_default_pii=True,
release=f"site@{GIT_SHA}"
)
Expand Down

0 comments on commit 04319c6

Please sign in to comment.