1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-23 19:44:20 +00:00

Install aiohttp and sqlalchemy integration

This commit is contained in:
Steffo 2019-09-10 13:24:38 +02:00
parent d4bcd61f2c
commit 8e898d301c

View file

@ -3,6 +3,8 @@ import typing
import asyncio import asyncio
import logging import logging
import sentry_sdk import sentry_sdk
from sentry_sdk.integrations.sqlalchemy import SqlalchemyIntegration
from sentry_sdk.integrations.aiohttp import AioHttpIntegration
from ..utils import * from ..utils import *
from ..network import * from ..network import *
from ..database import * from ..database import *
@ -134,7 +136,7 @@ class GenericBot:
self.loop = loop self.loop = loop
if sentry_dsn: if sentry_dsn:
log.debug("Sentry integration enabled") log.debug("Sentry integration enabled")
self.sentry = sentry_sdk.init(sentry_dsn) self.sentry = sentry_sdk.init(sentry_dsn, integrations=[AioHttpIntegration(), SqlalchemyIntegration()])
else: else:
log.debug("Sentry integration disabled") log.debug("Sentry integration disabled")
try: try: