Revert "Remove Sentry again"
divent / lint (push) Successful in 2m9s Details
divent / docker (push) Successful in 31s Details
divent / pypi (push) Successful in 1m15s Details

This reverts commit 0b245f735a.
This commit is contained in:
Michel Roux 2023-08-11 17:35:44 +02:00
parent fd8224be3f
commit c863e99de4
3 changed files with 471 additions and 446 deletions

View File

@ -12,6 +12,8 @@ from ics.alarm import DisplayAlarm
from oauthlib.oauth2 import OAuth2Error
from quart import Quart, redirect, render_template, request, session, url_for
from requests_oauthlib import OAuth2Session # type: ignore
import sentry_sdk
from sentry_sdk.integrations.quart import QuartIntegration
from uvicorn.middleware.proxy_headers import ProxyHeadersMiddleware
@ -31,6 +33,10 @@ QUART_DEBUG = getenv("QUART_DEBUG", False)
if QUART_DEBUG:
logging.basicConfig(level=logging.DEBUG)
SENTRY_DSN = getenv("SENTRY_DSN")
if SENTRY_DSN:
sentry_sdk.init(SENTRY_DSN, integrations=[QuartIntegration()])
API_BASE_URL = getenv("API_BASE_URL", "https://discordapp.com/api")
AUTHORIZATION_BASE_URL = f"{API_BASE_URL}/oauth2/authorize"
TOKEN_URL = f"{API_BASE_URL}/oauth2/token"

896
poetry.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -2,7 +2,7 @@
name = "divent"
version = "3.4.2"
description = "The discord scheduled event calendar generator"
authors = ["Xéfir Destiny"]
authors = ["Xéfir Destiny <xefir@crystalyx.net>"]
license = "WTFPL"
readme = "README.md"
homepage = "https://divent.crystalyx.net/"
@ -18,16 +18,17 @@ ics = "0.8.0.dev0"
python-dotenv = "^1.0.0"
quart = "^0.18.4"
requests-oauthlib = "^1.3.1"
uvicorn = "^0.23.0"
sentry-sdk = "^1.29.2"
uvicorn = "^0.23.2"
[tool.poetry.dev-dependencies]
black = "^23.3.0"
djlint = "^1.31.0"
flake8 = "^6.0.0"
black = "^23.7.0"
djlint = "^1.32.1"
flake8 = "^6.1.0"
flake8-alphabetize = "^0.0.21"
flake8-black = "^0.3.6"
mypy = "^1.4.1"
types-oauthlib = "^3.2.0.8"
mypy = "^1.5.0"
types-oauthlib = "^3.2.0.9"
[build-system]
requires = ["poetry-core>=1.0.0"]