Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump all deps and get lints passing #68

Merged
merged 4 commits into from
May 6, 2023
Rate limit · GitHub

Access has been restricted

You have triggered a rate limit.

Please wait a few minutes before you try again;
in some cases this may take up to an hour.

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
construct email client in bot state
Signed-off-by: Bradley Reynolds <bradley.reynolds@darbia.dev>
Rate limit · GitHub

Access has been restricted

You have triggered a rate limit.

Please wait a few minutes before you try again;
in some cases this may take up to an hour.

shenanigansd committed May 6, 2023
commit 7c946ddb5e66449ee8c24327f614222ad51388d0
2 changes: 2 additions & 0 deletions src/bot/__main__.py
Original file line number Diff line number Diff line change
@@ -10,6 +10,7 @@

from bot import constants
from bot.bot import Bot
from bot.utils.microsoft import build_ms_graph_client

from .utils.templates import JINJA_TEMPLATES

@@ -34,6 +35,7 @@ async def main() -> None:
bot = Bot(
guild_id=constants.Bot.guild_id,
http_session=aiohttp.ClientSession(),
graph_client=build_ms_graph_client(),
allowed_roles=roles,
command_prefix=get_prefix,
intents=intents,
4 changes: 4 additions & 0 deletions src/bot/bot.py
Original file line number Diff line number Diff line change
@@ -7,6 +7,7 @@
import discord
from discord.ext import commands
from jinja2 import Template
from msgraph.core import GraphClient

from bot import exts
from bot.utils.extensions import walk_extensions
@@ -50,6 +51,7 @@ def __init__(
*args,
allowed_roles: list,
http_session: aiohttp.ClientSession,
graph_client: GraphClient,
templates: dict[str, Template],
**kwargs,
):
@@ -68,6 +70,8 @@ def __init__(

self.http_session = http_session

self.graph_client = graph_client

self.templates = templates

self.all_extensions: frozenset[str] | None = None