| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
| |
Reorder imports to be consistenly grouped by standard library, third
party library, and local modules in that order thoughout the library.
|
| |
|
|
|
| |
Remove two duplicated entries from the quote mapping in commands.view.
These were introduced at the creation of this mapping in ea061ef.
|
| |
|
|
|
| |
Convert log("fmt" % args) to log("fmt", args) as the latter is lazy and
does not do the formating if the string is never logged.
|
| |
|
|
| |
Remove redundant paranthesis and checks from util.valid_icon_size.
|
| |
|
|
|
| |
Remove redundant parenthisis around await expressions. Left over from
f25091ef.
|
| |
|
|
|
|
|
|
| |
Restrict the values accepted by comparisons with booleans to be actual
booleans.
Minor breaking of undocumented behaviour in permissions; the value to
set bits to must be booleans (as indicated by the type error thrown).
|
| |
|
|
|
| |
Use the more explicit (and common) exc instead of e as the variable
holding the exception in except handlers.
|
| |
|
|
|
|
| |
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.
|
| |
|
|
| |
This reverts commit 96981210b3415e15446db0b702b07fef25c8b680.
|
| |
|
|
|
| |
Technically a breaking change. This is to be a parallel with the
Bot.add_check interface.
|
| | |
|
| |
|
|
| |
They can now delete all emoji
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
This will probably be reverted in 1 week.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
* type(x) is y is faster than isinstance(x, y)
* Re-arrange if-statements for common statements
* Drop handler getattr for most events that don't use it
|
| |
|
|
|
|
|
| |
* Skip user update if possible
* Drop copy.copy in favour of manual copy
Credit to Hornwitser for these findings.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
This allows for greedy "consume until you can't" behaviour similar to
typing.Optional but for lists.
|
| |
|
|
|
|
|
|
|
|
| |
Original code by zephyrkul.
This new parsing mode allows for backtracking in case of failure
when a typing.Union[..., NoneType] or a typing.Optional[...] is used.
This means that if a type would fail to parse, the view is undo'd to
a previous state, passing the default parameter to the callback, and
then continuing on the next parameter as if nothing had happened.
|
| | |
|
| |
|
|
| |
Remove incorrect note; extension of #1575
|
| |
|
|
| |
For when the hooks are not coroutines.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
| |
Adds the following:
* `slowmode_delay` for `TextChannel.edit`
* `slowmode_delay` attribute for `TextChannel`
|
| |
|
|
|
|
|
| |
In the docs, it says ``Note that bot accounts can only edit custom emojis they own.``
But after testing a bit. My bot was able to edit emojis in any guild that had the permissions `manage_roles`. Even if the bot didn't own the guild. Or was the original emoji uploader.
And I don't see any mentions of this in the API server or in the documentation. So I'm unsure how this ended up in here. It's possible I am misunderstanding the whole note. My bad if that's the case.
|
| |
|
| |
This also adds the 3.7 classifier as with this there are no 3.7 issues
|
| | |
|
| |
|
|
|
| |
New version contains many bugfixes, a couple new features and seemingly no breaking changes (for this lib's purposes at least).
Relevant changes: https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst#340-2018-08-25
|
| |
|
|
|
|
| |
having them appear in the docs ordered by their internal number
is not useful to the user. Sorting them by name
allows one to more quickly locate a voice region in the docs.
|
| | |
|