Skip to content

Commit 71eccf9

Browse files
committed
Add SqlalchemyIntegration for Sentry
1 parent 4cd8a99 commit 71eccf9

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

utils/sentry.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
import sentry_sdk
55

66
from sentry_sdk.integrations.logging import LoggingIntegration
7+
from sentry_sdk.integrations.sqlalchemy import SqlalchemyIntegration
78

89

910
ENABLE_SENTRY = os.getenv("ENABLE_SENTRY") == "1"
@@ -14,10 +15,13 @@
1415
enable_logs=True,
1516
send_default_pii=False,
1617
traces_sample_rate=1.0,
17-
integrations=[LoggingIntegration(
18-
level=logging.INFO,
19-
event_level=logging.ERROR,
20-
)],
18+
integrations=[
19+
LoggingIntegration(
20+
level=logging.INFO,
21+
event_level=logging.ERROR,
22+
),
23+
SqlalchemyIntegration(),
24+
],
2125
)
2226

2327

0 commit comments

Comments
 (0)