Commit Graph

35 Commits

Author SHA1 Message Date
7513c2138f Fix code style issues with Black 2021-09-05 21:34:20 +00:00
f6ea03230e Make parameters passed to Reaction.user keyword-only 2021-06-10 08:58:25 -04:00
c251c51cb1 Typehint Reaction 2021-06-10 08:58:10 -04:00
9181bf046b Rename Reaction.custom_emoji to Reaction.is_custom_emoji
This legacy attribute was apparently never changed to be consistent
with the rest of the library
2021-06-10 08:50:50 -04:00
99fc950510 Use f-strings in more places that were missed. 2021-04-08 06:02:47 -04:00
89456022cf Add __all__ to remaining modules 2021-04-07 02:30:32 -04:00
9d39b135f4 Modernize code to use f-strings
This also removes the encoding on the top, since Python 3 does it by
default. It also changes some methods to use `yield from`.
2021-04-04 07:03:53 -04:00
69bdc3a184 Change copyright year to present 2021-01-15 05:28:11 -05:00
6071607176 Bump copyright year to 2020
Closes #2510
2020-01-19 20:03:00 -05:00
87f9dcff9c Add support for clearing a specific reaction.
Closes #2440
2020-01-17 19:53:28 -05:00
c6539bbc61 Reaction's emoji can be a partial one too 2019-09-19 21:24:47 -04:00
3c9bcc2851 Improve documentation 2019-06-07 19:27:46 -04:00
fb02191b80 Organise documentation 2019-03-19 08:24:42 -04:00
806295a1be Add remove() to Reaction
Added a coro, `remove()` which takes in a sole parameter, `member`.
This new coro will remove the reaction by the provided member from the reactions message.

`message.remove_reaction(reaction, member)` was not removed as to not introduce breaking changes.
2019-02-14 20:21:09 -05:00
9656a21ebe Bumped copyright years to 2019. 2019-01-28 22:22:50 -05:00
cd218fa6a7 Remove Reaction.users "Python 3.4 usage" section
Remove nonsensical "Python 3.4" usage section from Reaction.users().
Left behind from f25091ef.
2018-08-28 23:50:52 -04:00
a329565e74 Fix Reaction.users documentation 2018-08-22 21:39:09 -04:00
f25091efe1 Drop support for Python 3.4 and make minimum version 3.5.2. 2018-06-10 18:10:00 -04:00
3112e1c17e Add intersphinx 2018-01-06 17:23:59 -05:00
e0f02f1775 Rename AsyncIterator.get to next to prevent shadowing. 2017-07-04 10:45:38 -04:00
649e4de149 Add Reaction.__str__ 2017-06-26 01:27:09 -04:00
d239cc2666 Implement "partial" message events.
These are events that get triggered regardless of the state of the
message cache. Useful for getting data from before the bot was booted.
2017-06-09 18:36:59 -04:00
f4e01b3a92 Make supported operations stand out more than attributes. 2017-05-20 02:08:34 -04:00
f73eb087c9 Use describe instead of tables for supported operations. 2017-05-13 18:48:14 -04:00
1fc08bc5a2 Remove unused imports. 2017-04-18 04:22:35 -04:00
2abdbc70c2 Implement utilities for AsyncIterator.
Closes #473.
2017-02-11 23:34:19 -05:00
ff9f5749e1 Update copyright year to 2017. 2017-01-20 23:19:19 -05:00
ae6fb54b1b Make Reaction.users return an async iterator. 2017-01-11 21:20:28 -05:00
5e6bfecb07 Move away from StateContext and use ConnectionState directly. 2017-01-03 09:52:10 -05:00
d5b616fa11 Rename MessageChannel abc to Messageable. 2017-01-03 09:52:09 -05:00
dceba9d962 Add useful repr to all data classes. 2017-01-03 09:52:06 -05:00
c187d87dae Re-add support for reactions.
We now store emojis in a global cache and make things like adding
and removing reactions part of the stateful Message class.
2017-01-03 09:51:57 -05:00
44624b7f44 Documentation fixes. 2016-11-17 20:42:06 -05:00
4d87b2f817 Inject full Emoji to Reaction if we have it.
Reaction objects with custom Emoji are partial. If we know of this Emoji
(can find it on this client) then inject it. Otherwise, leave it as a
hollow Emoji. We can still react with a hollow Emoji, but can't get other
metadata about it.
2016-11-03 04:39:45 -04:00
c4acc0e1a1 Add support for reactions.
Reactions can be be standard emojis, or custom server emojis.

Adds
 - add/remove_reaction
 - get_reaction_users
 - Messages have new field reactions
 - new events - message_reaction_add, message_reaction_remove
 - new permission - add_reactions
2016-10-27 21:36:32 -07:00