Skip to content

Commit 9dba074

Browse files
scattered-developmentscott charlesworthJibola
authored
Raven changed to Sentry SDK (#51)
Co-authored-by: scott charlesworth <scott@kenja.io> Co-authored-by: Jib <jib.adegunloye@mongodb.com>
1 parent bdc9590 commit 9dba074

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

{{cookiecutter.project_slug}}/backend/app/app/worker/tests.py

+11-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,19 @@
1-
from raven import Client
1+
import sentry_sdk
22
import asyncio
33

44
from app.core.celery_app import celery_app
55
from app.core.config import settings
66

7-
client_sentry = Client(settings.SENTRY_DSN)
7+
client_sentry = sentry_sdk.init(
8+
dsn=settings.SENTRY_DSN,
9+
# Set traces_sample_rate to 1.0 to capture 100%
10+
# of transactions for tracing.
11+
traces_sample_rate=1.0,
12+
# Set profiles_sample_rate to 1.0 to profile 100%
13+
# of sampled transactions.
14+
# We recommend adjusting this value in production.
15+
profiles_sample_rate=1.0,
16+
)
817

918

1019
@celery_app.task(acks_late=True)

{{cookiecutter.project_slug}}/backend/app/pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ dependencies = [
2727
"passlib[bcrypt]>=1.7.4",
2828
"tenacity>=8.1.0",
2929
"emails>=0.6.0",
30-
"raven>=6.10.0",
30+
"sentry-sdk>=2.13.0",
3131
"jinja2>=3.1.2",
3232
"python-jose[cryptography]>=3.3.0",
3333
"pydantic>=2.0,<2.7",

0 commit comments

Comments
 (0)