X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/6c74d7c9389a009ecda329c445d8f15c75326229..ce3795b6c4f878c496b4d46193e3379f8efb077b:/src/wolnelektury/settings/__init__.py diff --git a/src/wolnelektury/settings/__init__.py b/src/wolnelektury/settings/__init__.py index 78b556d78..8e0815b3f 100644 --- a/src/wolnelektury/settings/__init__.py +++ b/src/wolnelektury/settings/__init__.py @@ -1,5 +1,10 @@ -# -*- coding: utf-8 -*- +# This file is part of Wolnelektury, licensed under GNU Affero GPLv3 or later. +# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information. +# # Django settings for wolnelektury project. +import sentry_sdk +from sentry_sdk.integrations.django import DjangoIntegration + from .apps import * from .basic import * from .auth import * @@ -16,3 +21,14 @@ try: from wolnelektury.localsettings import * except ImportError: pass + + +try: + SENTRY_DSN +except NameError: + pass +else: + sentry_sdk.init( + dsn=SENTRY_DSN, + integrations=[DjangoIntegration()] + )