aboutsummaryrefslogtreecommitdiffstats
path: root/bot/log.py
diff options
context:
space:
mode:
authorGravatar Chris Lovering <[email protected]>2023-11-25 22:22:00 +0000
committerGravatar Chris Lovering <[email protected]>2023-11-25 22:22:00 +0000
commit69c08d196f8bf8fe64fc954f2f4b9f19e10e078c (patch)
tree4570950b3907ee1a852fdcfa180b4c0e42718d46 /bot/log.py
parentUpdate to pydantic 2.0 (diff)
Remove the need for calling dotenv manually by using pydantic
Diffstat (limited to 'bot/log.py')
-rw-r--r--bot/log.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/bot/log.py b/bot/log.py
index b4431bc3..9ebc89a7 100644
--- a/bot/log.py
+++ b/bot/log.py
@@ -10,7 +10,7 @@ from pydis_core.utils import logging as core_logging
from sentry_sdk.integrations.logging import LoggingIntegration
from sentry_sdk.integrations.redis import RedisIntegration
-from bot.constants import Logging
+from bot.constants import Client, GIT_SHA, Logging
def setup() -> None:
@@ -59,12 +59,12 @@ def setup_sentry() -> None:
)
sentry_sdk.init(
- dsn=os.environ.get("BOT_SENTRY_DSN"),
+ dsn=Client.sentry_dsn,
integrations=[
sentry_logging,
RedisIntegration(),
],
- release=f"bot@{os.environ.get('GIT_SHA')}",
+ release=f"bot@{GIT_SHA}",
traces_sample_rate=0.5,
_experiments={
"profiles_sample_rate": 0.5,