11diff --git a/src/_discord/client.py b/src/_discord/client.py
2- index e6fa165..9c681a5 100644
2+ index 0be4855..08c6469 100644
33--- a/src/_discord/client.py
44+++ b/src/_discord/client.py
5- @@ -30,7 +30,7 @@ import logging
6- import signal
7- import sys
8- import traceback
9- - from typing import TYPE_CHECKING, Any, Callable, Coroutine, Generator, Sequence, TypeVar
10- + from typing import TYPE_CHECKING, Any, Callable, Coroutine, Generator, Optional, Sequence, TypeVar
11-
12- import aiohttp
13-
14- @@ -109,7 +109,7 @@ def _cleanup_loop(loop: asyncio.AbstractEventLoop) -> None:
15- loop.run_until_complete(loop.shutdown_asyncgens())
16- finally:
17- _log.info("Closing the event loop.")
18- - loop.close()
19- + loop.call_soon(loop.close)
20-
21-
22- class Client:
235@@ -482,7 +482,7 @@ class Client:
246
257 # login state management
@@ -29,16 +11,7 @@ index e6fa165..9c681a5 100644
2911 """|coro|
3012
3113 Logs in the client with the specified credentials.
32- @@ -492,6 +492,8 @@ class Client:
33- token: :class:`str`
34- The authentication token. Do not prefix this token with
35- anything as the library will do it for you.
36- + bot: bool
37- + Is the token from a bot account.
38-
39- Raises
40- ------
41- @@ -511,7 +513,7 @@ class Client:
14+ @@ -511,7 +511,7 @@ class Client:
4215
4316 _log.info("logging in using static token")
4417
@@ -47,16 +20,16 @@ index e6fa165..9c681a5 100644
4720 self._connection.user = ClientUser(state=self._connection, data=data)
4821
4922 async def connect(self, *, reconnect: bool = True) -> None:
50- @@ -646 ,7 +648 ,7 @@ class Client:
23+ @@ -645 ,7 +645 ,7 @@ class Client:
5124 self._connection.clear()
5225 self.http.recreate()
5326
5427- async def start(self, token: str, *, reconnect: bool = True) -> None:
55- + async def start(self, token: str, *, reconnect: bool = True, bot: Optional[ bool] = True) -> None:
28+ + async def start(self, token: str, *, reconnect: bool = True, bot: bool = True) -> None:
5629 """|coro|
5730
5831 A shorthand coroutine for :meth:`login` + :meth:`connect`.
59- @@ -656 ,7 +658 ,7 @@ class Client:
32+ @@ -655 ,7 +655 ,7 @@ class Client:
6033 TypeError
6134 An unexpected keyword argument was received.
6235 """
0 commit comments