Skip to content

Commit 3c4a001

Browse files
ci: correct from checks.
1 parent 2d23860 commit 3c4a001

File tree

16 files changed

+123
-106
lines changed

16 files changed

+123
-106
lines changed

interactions/api/events/internal.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ async def an_event_handler(event: ChannelCreate):
1919
While all of these events are documented, not all of them are used, currently.
2020
2121
"""
22+
2223
import re
2324
import typing
2425
from typing import Any, Optional, TYPE_CHECKING, Type

interactions/api/gateway/gateway.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Outlines the interaction between interactions and Discord's Gateway API."""
2+
23
import asyncio
34
import logging
45
import sys

interactions/api/gateway/websocket.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -315,12 +315,10 @@ async def _start_bee_gees(self) -> None:
315315
return
316316

317317
@abstractmethod
318-
async def _identify(self) -> None:
319-
...
318+
async def _identify(self) -> None: ...
320319

321320
@abstractmethod
322-
async def _resume_connection(self) -> None:
323-
...
321+
async def _resume_connection(self) -> None: ...
324322

325323
@abstractmethod
326324
async def send_heartbeat(self) -> None:

interactions/api/http/http_client.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""This file handles the interaction with discords http endpoints."""
2+
23
import asyncio
34
import inspect
45
import os

interactions/api/http/http_requests/channels.py

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,7 @@ async def get_channel_messages(
4141
self,
4242
channel_id: "Snowflake_Type",
4343
limit: int = 50,
44-
) -> list[discord_typings.MessageData]:
45-
...
44+
) -> list[discord_typings.MessageData]: ...
4645

4746
@overload
4847
async def get_channel_messages(
@@ -51,8 +50,7 @@ async def get_channel_messages(
5150
limit: int = 50,
5251
*,
5352
around: "Snowflake_Type | None" = None,
54-
) -> list[discord_typings.MessageData]:
55-
...
53+
) -> list[discord_typings.MessageData]: ...
5654

5755
@overload
5856
async def get_channel_messages(
@@ -61,8 +59,7 @@ async def get_channel_messages(
6159
limit: int = 50,
6260
*,
6361
before: "Snowflake_Type | None" = None,
64-
) -> list[discord_typings.MessageData]:
65-
...
62+
) -> list[discord_typings.MessageData]: ...
6663

6764
@overload
6865
async def get_channel_messages(
@@ -71,8 +68,7 @@ async def get_channel_messages(
7168
limit: int = 50,
7269
*,
7370
after: "Snowflake_Type | None" = None,
74-
) -> list[discord_typings.MessageData]:
75-
...
71+
) -> list[discord_typings.MessageData]: ...
7672

7773
async def get_channel_messages(
7874
self,
@@ -263,8 +259,7 @@ async def create_channel_invite(
263259
unique: bool = False,
264260
*,
265261
reason: str | None = None,
266-
) -> discord_typings.InviteData:
267-
...
262+
) -> discord_typings.InviteData: ...
268263

269264
@overload
270265
async def create_channel_invite(
@@ -277,8 +272,7 @@ async def create_channel_invite(
277272
*,
278273
target_user_id: "Snowflake_Type | None" = None,
279274
reason: str | None = None,
280-
) -> discord_typings.InviteData:
281-
...
275+
) -> discord_typings.InviteData: ...
282276

283277
@overload
284278
async def create_channel_invite(
@@ -291,8 +285,7 @@ async def create_channel_invite(
291285
*,
292286
target_application_id: "Snowflake_Type | None" = None,
293287
reason: str | None = None,
294-
) -> discord_typings.InviteData:
295-
...
288+
) -> discord_typings.InviteData: ...
296289

297290
async def create_channel_invite(
298291
self,

interactions/api/voice/opus.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,10 @@
2121
lib_opus = MISSING
2222

2323

24-
class EncoderStructure(ctypes.Structure):
25-
...
24+
class EncoderStructure(ctypes.Structure): ...
2625

2726

28-
class DecoderStructure(ctypes.Structure):
29-
...
27+
class DecoderStructure(ctypes.Structure): ...
3028

3129

3230
EncoderStructurePointer = ctypes.POINTER(EncoderStructure)

interactions/client/client.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -408,9 +408,9 @@ def __init__(
408408
"""A dictionary of registered application commands: `{scope: [commands]}`"""
409409
self._interaction_lookup: dict[str, InteractionCommand] = {}
410410
"""A dictionary of registered application commands: `{name: command}`"""
411-
self.interaction_tree: Dict[
412-
"Snowflake_Type", Dict[str, InteractionCommand | Dict[str, InteractionCommand]]
413-
] = {}
411+
self.interaction_tree: Dict["Snowflake_Type", Dict[str, InteractionCommand | Dict[str, InteractionCommand]]] = (
412+
{}
413+
)
414414
"""A dictionary of registered application commands in a tree"""
415415
self._component_callbacks: Dict[str, Callable[..., Coroutine]] = {}
416416
self._regex_component_callbacks: Dict[re.Pattern, Callable[..., Coroutine]] = {}

interactions/client/const.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
has_feature_flag Callable[[str], bool]: A function that returns whether a feature flag is enabled.
3737
3838
"""
39+
3940
import inspect
4041
import logging
4142
import os
@@ -183,8 +184,7 @@ def __bool__(self) -> bool:
183184
return False
184185

185186

186-
class MentionPrefix(Sentinel):
187-
...
187+
class MentionPrefix(Sentinel): ...
188188

189189

190190
GLOBAL_SCOPE = GlobalScope()

interactions/ext/hybrid_commands/hybrid_slash.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -312,9 +312,11 @@ async def __call__(self, context: PrefixedContext, *args, **kwargs) -> None:
312312
def slash_to_prefixed(cmd: HybridSlashCommand) -> _HybridToPrefixedCommand: # noqa: C901 there's nothing i can do
313313
prefixed_cmd = _HybridToPrefixedCommand(
314314
name=str(cmd.sub_cmd_name) if cmd.is_subcommand else str(cmd.name),
315-
aliases=list(_values_wrapper(cmd.sub_cmd_name.to_locale_dict()))
316-
if cmd.is_subcommand
317-
else list(_values_wrapper(cmd.name.to_locale_dict())),
315+
aliases=(
316+
list(_values_wrapper(cmd.sub_cmd_name.to_locale_dict()))
317+
if cmd.is_subcommand
318+
else list(_values_wrapper(cmd.name.to_locale_dict()))
319+
),
318320
help=str(cmd.description),
319321
callback=cmd.callback,
320322
checks=cmd.checks,

interactions/ext/mypy/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
plugins = "interactions.ext.mypy"
1818
```
1919
"""
20+
2021
from functools import partial
2122
from typing import Callable, Optional, Type
2223
from mypy.plugin import Plugin, ClassDefContext

0 commit comments

Comments
 (0)