From c8882387e0ad345ca5d069bf8d6ed7f9845d772a Mon Sep 17 00:00:00 2001 From: Egor Matveev Date: Mon, 28 Feb 2022 21:21:13 +0300 Subject: [PATCH] sentry --- Sprint/settings.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/Sprint/settings.py b/Sprint/settings.py index 2f977b5..3f02127 100644 --- a/Sprint/settings.py +++ b/Sprint/settings.py @@ -14,6 +14,9 @@ import os # Build paths inside the project like this: os.path.join(BASE_DIR, ...) +import sentry_sdk +from sentry_sdk.integrations.django import DjangoIntegration + BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) @@ -163,3 +166,17 @@ CONSTS = { "testing_status": "Testing", "ok_status": "OK", } + +sentry_sdk.init( + dsn="https://bd56bba96dbe4017a792810a8be6cfc1@o1155463.ingest.sentry.io/6235928", + integrations=[DjangoIntegration()], + + # Set traces_sample_rate to 1.0 to capture 100% + # of transactions for performance monitoring. + # We recommend adjusting this value in production. + traces_sample_rate=1.0, + + # If you wish to associate users to errors (assuming you are using + # django.contrib.auth) you may enable sending PII data. + send_default_pii=True +)