Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Pass the Saleor version string to Sentry as release number (#9642)

Patryk Zawadzkid8fee224138f
diff --git a/saleor/settings.py b/saleor/settings.py
index d44a2debc6..2041dd7b48 100644
--- a/saleor/settings.py
+++ b/saleor/settings.py
@@ -19,6 +19,7 @@ from sentry_sdk.integrations.celery import CeleryIntegration
from sentry_sdk.integrations.django import DjangoIntegration
from sentry_sdk.integrations.logging import ignore_logger
+from . import __version__
from .core.languages import LANGUAGES as CORE_LANGUAGES
@@ -575,7 +576,7 @@ def SENTRY_INIT(dsn: str, sentry_opts: dict):
Will only be called if SENTRY_DSN is not None, during core start, can be
overriden in separate settings file.
"""
- sentry_sdk.init(dsn, **sentry_opts)
+ sentry_sdk.init(dsn, release=__version__, **sentry_opts)
ignore_logger("graphql.execution.utils")
ignore_logger("graphql.execution.executor")