diff options
| author | 2022-08-22 20:28:51 +0100 | |
|---|---|---|
| committer | 2022-08-22 20:28:51 +0100 | |
| commit | f124a5a12776f3a1cf87a6e5c2e86bc221c55c27 (patch) | |
| tree | 0b07eb7b1d69b71e04900653ce852ee00c8dface | |
| parent | Merge pull request #16 from python-discord/dependabot/pip/flake8-5.0.4 (diff) | |
| parent | Ensure monkeypatches from bot-core are ran on startup (diff) | |
Merge pull request #17 from python-discord/botocore-monkeypatching
| -rw-r--r-- | arthur/__init__.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arthur/__init__.py b/arthur/__init__.py index 0d837f6..c2c5154 100644 --- a/arthur/__init__.py +++ b/arthur/__init__.py @@ -5,6 +5,7 @@ from functools import partial from typing import TYPE_CHECKING import loguru +from botcore.utils import apply_monkey_patches if TYPE_CHECKING: from arthur.bot import KingArthur @@ -12,6 +13,8 @@ if TYPE_CHECKING: logger = loguru.logger.opt(colors=True) logger.opt = partial(logger.opt, colors=True) +apply_monkey_patches() + # On Windows, the selector event loop is required for aiodns. if os.name == "nt": asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy()) |