| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
Fixes #2002
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added access to:
* `/users/@me/guilds`
* `/guilds/{guild_id}`
* `/guilds/{guild_id}/members/{member_id}`
BREAKING CHANGE:
* `get_user_info` -> `fetch_user_info` to match naming scheme.
Remove useless note
Remove `reverse` and corresponding documentation
Update documentation to reflect #1988
Rename `get_` HTTP functions to `fetch_`
Breaking Changes:
* `get_message` -> `fetch_message`
* `get_invite` -> `fetch_invite`
* `get_user_profile` -> `fetch_user_profile`
* `get_webhook_info` -> `fetch_webhook`
* `get_ban` -> `fetch_ban`
Fix InviteConverter, update migrating.rst
Rename get_message to fetch_message
|
| | |
|
| |
|
|
| |
Fix #1809
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
Reorder imports to be consistenly grouped by standard library, third
party library, and local modules in that order thoughout the library.
|
| |
|
|
|
|
| |
Use bare raise statement when reraising the exception that occured, and
remove unused exception variables. Also remove a pointless exception
handler in discord.opus.
|
| |
|
|
| |
Add exception qualifier(s) to bare except clauses swallowing exceptions.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Introduce a new internal type, SnowflakeList, which has better memory
footprint over a regular list or set of roles. It is suspected that
there will be a 9x reduction of memory for every Emoji instance and a
48 byte saving per Member instance. However, these savings will
probably only be evident on larger bots.
As a consequence of this change, Member.roles is now computed lazily.
Currently I am not sure if I want to do the initial sorting on the
SnowflakeList for Member, as this comes with a O(n log n) cost when
creating a Member for little purpose since SnowflakeList.has is not
overly relied on. If CPU time becomes an issue this might change.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds the following APIs:
* Guild.get_role
This removes the following APIs:
* Guild.role_hierarchy
To compensate for the removed APIs, Guild.roles is now a sorted list
based on hierarchy. The first element will always be the @everyone
role.
This speeds up access at the cost of some memory, theoretically.
|
| |
|
|
|
|
|
| |
Adds the following:
* `slowmode_delay` for `TextChannel.edit`
* `slowmode_delay` attribute for `TextChannel`
|
| | |
|
| |
|
|
| |
Adjust whitespace to be consistent with the rest of the library.
|
| |
|
|
| |
Left over from various refactoring and rewrites.
|
| | |
|
| | |
|
| |
|
|
| |
Mostly dealing with permissions, also fixes Raw Events inclusion.
|
| |
|
|
| |
Fix #1254
|
| | |
|
| |
|
|
|
|
| |
Should make the category-only edit cases more straightforward since
it does not rely on other guilds in the cache, outside of the category
itself.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This adds:
* CategoryChannel, which represents a category
* Guild.by_category() which traverses the channels grouping by category
* Guild.categories to get a list of categories
* abc.GuildChannel.category to get the category a channel belongs to
* sync_permissions keyword argument to abc.GuildChannel.edit to sync
permissions with a pre-existing or new category
* category keyword argument to abc.GuildChannel.edit to move a channel
to a category
|
| |
|
|
|
|
|
|
|
|
|
| |
Apparently this is unsupported.
Affected functions include:
* abc.Messageable.send
* Message.delete
* TextChannel.delete_messages
* TextChannel.purge
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
In Discord, if the @everyone role has an explicit allow but a later
role has an explicit deny, the permission is denied rather than allowed
despite the fact that on Discord, allows have a higher priority than
denies.
This is because the @everyone role is supposed to be the first role to
be applied, while the rest could be applied in an aggregate fashion.
Fixes #630.
|
| | |
|
| |
|
|
| |
The previous restriction was unwarranted.
|
| | |
|
| |
|
|
|
| |
Some cases of is_connected is not set so we need to force it to clear
it anyway.
|
| | |
|
| | |
|
| |
|
|
| |
Most routes now have a 'reason' keyword argument.
|
| |
|
|
|
| |
Minor speed increase when we're not doing excessive attribute
access or any type of formatting.
|
| | |
|
| |
|
|
|
|
| |
This now sort of respects "Awaiting Endpoint..." waiting. I haven't
actually tested out this case since it's hard to get it. However this
new code does work with the regular connection flow.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a complete redesign of the old voice code.
A list of major changes is as follows:
* The voice websocket will now automatically reconnect with
exponential back-off just like the regular Client does.
* Removal of the stream player concept.
* Audio now gracefully pauses and resumes when a disconnect is found.
* Introduce a discord.AudioSource concept to abstract streams
* Flatten previous stream player functionality with the
VoiceClient, e.g. player.stop() is now voice_client.stop()
* With the above re-coupling this means you no longer have to
store players anywhere.
* The after function now requires a single parameter, the error,
if any existed. This will typically be None.
A lot of this design is experimental.
|
| |
|
|
|
|
|
| |
This is a breaking change. No longer does Messageable.send have a
filename keyword argument, instead this is all handled through the
discord.File model. To upload many files you must specify a list
of discord.File objects.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
This is a breaking change. Move these two to TextChannel since the
other things that implement Messageable cannot reliably do bulk delete
actions in their respective channels.
|
| |
|
|
|
|
| |
Also make it work on user accounts.
Fixes #456.
|
| | |
|
| |
|
|
| |
Fixes #480.
|
| |
|
|
| |
Closes #473.
|
| | |
|