1
0
mirror of https://github.com/Rapptz/discord.py.git synced 2025-09-19 14:38:43 +00:00
Commit Graph

533 Commits

Author SHA1 Message Date
66c6be50d8 Prepare for the discord.com domain rename 2020-05-23 21:44:30 -04:00
13a3f760e6 Fix timeout issues with fetching members via query_members
This uses the nonce field to properly disambiguate queries. There's
also some redesigning going on behind the scenes and minor clean-up.
Originally I planned on working on this more to account for the more
widespread chunking changes planned for gateway v7 but I realized that
this would indiscriminately slow down everyone else who isn't planning
on working with intents for now.

I will work on the larger chunking changes in the future, should time
allow for it.
2020-05-10 19:35:45 -04:00
d853a57e86 Rename allowed mention parameters to allowed_mentions 2020-04-04 13:22:51 -04:00
730d79d60a Allow introspection and setting of global allowed mention configuration 2020-04-04 12:49:39 -04:00
481b335f2d Fix various implementation bugs with allowed mentions 2020-04-04 12:45:17 -04:00
041785937e Add support for configuring allowed mentions per message or bot wide. 2020-04-04 07:40:51 -04:00
6c764465c0 Fix regression with Member.activities not clearing 2020-04-04 03:17:31 -04:00
403651a144 Change default close code to 4000 instead of 1000.
This prevents our sessions from being invalidated by Discord which
caused a lot of failures when resuming. This caused an unnecessary
amount of IDENTIFYs to happen depending on the circumstances.

Closes 

See also 
2020-04-04 01:42:08 -04:00
7b3335a0b0 Don't add None to Member.activities tuple 2020-04-04 01:12:46 -04:00
6525ac948c fixing the BaseActivity links 2020-04-04 01:12:08 -04:00
17f343b03e Minor documentation fixes 2020-01-21 21:34:58 -05:00
02397306b2 Drop superfluous zero in version related changes in the documentation 2020-01-21 03:47:56 -05:00
6071607176 Bump copyright year to 2020
Closes 
2020-01-19 20:03:00 -05:00
5f7a97ff96 Document BaseActivity 2020-01-14 22:09:24 -05:00
42a084028c Expose _ActivityTag as BaseActivity to easily refer to. 2020-01-14 20:56:00 -05:00
c62b6c3e88 Fix more deprecation warnings for 3.8 2019-11-26 05:19:11 -05:00
a6f61dcbde Fix all deprecation warnings for 3.8 2019-11-20 02:30:19 -05:00
ea3d119ca6 Use X-Ratelimit-Reset-After header by default.
There is now an option to turn it off, of course.
2019-08-27 18:41:32 -04:00
2f7e875a76 Strip tokens before use.
Closes 
2019-08-27 04:59:17 -04:00
cf79816c5d Allow disabling the message cache with max_messages=None
This also changes the default to 1000 instead of 5000 since it can
take some time for small bots to cycle through the default and they
make up the majority of it.
2019-08-27 04:50:50 -04:00
c7a1f5e6e9 Disambiguate and normalize documentation for non-bot only methods 2019-08-11 18:50:31 -04:00
18fe2035ef Document that the cache retrieval functions require an int ID.
Closes 
2019-07-23 04:01:14 -04:00
92b3a4f8f4 on_member_leave => on_member_remove 2019-07-18 18:06:42 -04:00
7cec42c8f1 Fix doc URL in Client.fetch_guild 2019-07-18 18:06:26 -04:00
f13c1be171 Better knowledge on how guild_subscriptions work now. 2019-07-15 08:01:57 -04:00
ca2ee0655d Add versionadded for guild_subscriptions option. 2019-07-10 05:00:13 -04:00
7b8d50a988 Add support for guild subscriptions. 2019-07-10 04:51:27 -04:00
8f691ae775 Only return exception in Client.run when it's not cancelled. 2019-06-20 23:04:38 -04:00
b2f247bef3 Propagate exception in Client.run
Fix 
2019-06-20 23:00:45 -04:00
dfcf9cdb0a Rename error type for X.fetch_channel(s). 2019-06-12 00:47:42 -04:00
34b93c757c docs: Fix minor typo 2019-06-12 00:47:42 -04:00
3c9bcc2851 Improve documentation 2019-06-07 19:27:46 -04:00
f7c6c5995d Implementing GET '/channels/:id' & '/guilds/:id/channels'
Signed-off-by: NCPlayz <chowdhurynadir0@outlook.com>
2019-06-07 19:12:59 -04:00
82b54933e2 Add asyncio.Task subclass for better __repr__ for events. 2019-05-19 19:17:29 -04:00
38eb2b4828 Validate kwargs in Client.start 2019-05-19 19:17:27 -04:00
123e151978 Add back signal handling to Client.run
Apparently Python does not transform SIGTERM to KeyboardInterrupt as
nicely as I thought.
2019-05-11 14:40:31 -04:00
de6240f1e7 Rewrite loop cleanup code (again...) and remove signal handling.
This should hopefully be the last time I touch this.
2019-04-26 01:57:33 -04:00
186d9a7f9c Use a regular boolean instead of asyncio.Event for close status. 2019-04-25 01:57:32 -04:00
ceb154718d Add note about overriding Client.close vs Client.logout 2019-04-18 20:04:11 -04:00
b1fae0861a add read-only cached_messages property to Client
For those of us who want access to this sweet trove of zero hop messages
2019-04-17 22:41:59 -04:00
14d66e7b9c Internal consistency with message related HTTPClient methods 2019-04-14 21:05:20 -04:00
50dcdac5ca [commands] Fix references in Bot to actually link.
Exceptions can't seem to link due to a bug in Sphinx.
2019-04-10 05:13:30 -04:00
4df0f79a6b Add notes warning that fetch_ methods are api calls
Also recommends using cache attributes/methods instead
2019-04-10 00:55:45 -04:00
e77dec85e9 Fix cleanup code on Linux not working properly. 2019-04-09 00:56:36 -04:00
dcdcf1adac Stop the event loop if it's running during cleanup.
Also handle the coroutine directly instead of using run_until_complete
2019-04-09 00:14:42 -04:00
7acb7de195 Add notes stating what Guild.fetch_guild and Guild.fetch_guilds returns
Also fixed two typos.
2019-04-08 18:17:40 -04:00
61ee88b0fc Fix oversight where on_disconnect did not get called on WS termination. 2019-04-08 07:45:05 -04:00
72b6152e96 Client.event raises TypeError instead of ClientException. 2019-04-07 22:33:38 -04:00
84c1eac62a Don't raise an exception during the signal handlers. 2019-04-07 16:10:44 -04:00
239d430539 Simplify bot loop cleanup routine.
Attempted solution for 
2019-04-06 21:29:57 -04:00