diff --git a/discord/client.py b/discord/client.py index 8837dc652..24904025b 100644 --- a/discord/client.py +++ b/discord/client.py @@ -3153,10 +3153,13 @@ class Client: ----------- \*recipients: :class:`~discord.abc.Snowflake` An argument :class:`list` of :class:`discord.User` to have in - your group. + your group. Groups cannot be created with only one person, + but they can be created with zero people. Raises ------- + TypeError + Only one recipient was given. HTTPException Failed to create the group direct message. @@ -3165,6 +3168,9 @@ class Client: :class:`.GroupChannel` The new group channel. """ + if len(recipients) == 1: + raise TypeError('Cannot create a group with only one recipient') + users: List[_Snowflake] = [u.id for u in recipients] state = self._connection data = await state.http.start_group(users) diff --git a/discord/types/experiment.py b/discord/types/experiment.py index a8e5b7781..d98562623 100644 --- a/discord/types/experiment.py +++ b/discord/types/experiment.py @@ -58,9 +58,7 @@ Filters = List[ Tuple[Literal[3013771838], Tuple[Tuple[Literal[3013771838], List[int]]]], # IDs Tuple[Literal[4148745523], Tuple[Tuple[Literal[4148745523], List[int]]]], # HUB_TYPE Tuple[Literal[188952590], Tuple[Tuple[Literal[188952590], bool]]], # VANITY_URL - Tuple[ - Literal[2294888943], Tuple[Tuple[Literal[2690752156], int], Tuple[Literal[1982804121], int]] - ], # RANGE_BY_HASH + Tuple[Literal[2294888943], Tuple[Tuple[Literal[2690752156], int], Tuple[Literal[1982804121], int]]], # RANGE_BY_HASH ] ]