Commit Graph

255 Commits

Author SHA1 Message Date
44a44e938f Reformat entire project with ruff instead of black 2025-08-18 20:16:10 -04:00
983a9b8f94 Use Unpack where it's possible 2025-08-15 05:36:36 -04:00
705eb2c2a5 Update to support new pin endpoints 2025-08-13 20:47:14 -04:00
50caa3c82c Add support for components V2
Co-authored-by: Michael H <michael@michaelhall.tech>
Co-authored-by: Soheab <33902984+Soheab@users.noreply.github.com>
Co-authored-by: owocado <24418520+owocado@users.noreply.github.com>
Co-authored-by: Jay3332 <40323796+jay3332@users.noreply.github.com>
Co-authored-by: Danny <1695103+Rapptz@users.noreply.github.com>
2025-08-13 20:37:23 -04:00
774b934f74 Add support for guest invites 2025-07-02 18:59:40 -04:00
fbe2b358fc Add note about NotFound for Messageable.send
Fix #10116
2025-02-28 18:03:47 -05:00
8953938a53 Update Pyright to v1.1.394 2025-02-18 03:29:09 -05:00
a0b0a97e52 Support enforce_nonce and add random nonce for message creation 2024-10-27 14:49:41 -04:00
c8ecbd8d10 Add Message.forward flag 2024-10-22 12:01:34 -04:00
354ae4208c Fix abc.GuildChannel.clone implementations 2024-10-16 18:49:41 -04:00
a5f9350ff2 Add category parameter to abc.GuildChannel.clone 2024-10-10 05:22:52 -04:00
04b2e494f7 Fix documentation for abc.GuildChannel.move to be more clear 2024-07-21 18:44:07 -04:00
9eac36501a Allow deletion race conditions to work with purge 2024-06-14 18:08:12 -04:00
bb1d09a13f Account for user installations in Channel.permissions_for
Co-authored-by: owocado <24418520+owocado@users.noreply.github.com>
2024-06-12 14:25:49 -04:00
e43bd8692c Add support for Polls
Co-authored-by: owocado <24418520+owocado@users.noreply.github.com>
Co-authored-by: Josh <8677174+bijij@users.noreply.github.com>
Co-authored-by: Trevor Flahardy <75498301+trevorflahardy@users.noreply.github.com>
2024-05-10 06:14:12 -04:00
e25b7ff3f8 Support for avatar decorations
Co-authored-by: Danny <1695103+Rapptz@users.noreply.github.com>
Co-authored-by: owocado <24418520+owocado@users.noreply.github.com>
2024-01-26 20:12:07 -05:00
9ce733321b Add support for setting voice channel status 2023-12-26 05:32:21 -05:00
44284ae107 Rewrite voice connection internals 2023-09-28 17:51:22 -04:00
5e9f679178 Fix NameError in GuildChannel.create_invite
Move InviteTarget out of type checking
2023-07-22 00:22:55 -04:00
630b2a1e55 Update pyright version 2023-07-01 18:26:27 -04:00
c5da0fe7c1 Remove and address stale TODO comments 2023-06-11 12:41:04 -04:00
df01db3490 Initial support for pomelo migration 2023-05-19 20:59:19 -04:00
23352fba79 Fix exception raised by around strategy when the limit is set to 100/101 2023-05-06 05:20:37 -04:00
fd9f3e9eff Update docs with references to text in stage 2023-02-25 03:27:04 -05:00
da4651c97c Implement Messageable for StageChannel
Fix #9248
2023-02-25 03:13:55 -05:00
e6ef43139f Don't store finished views/modals 2023-02-13 23:52:40 -05:00
183675be74 Add support for silent messages 2023-02-08 15:40:33 -05:00
887ddbb4b6 Fix implicit permission resolution for Thread
Fix #9153
2022-12-29 07:17:41 -05:00
Eta
4122bef8ee Fix async iterators requesting past their bounds
This affects Messageable.history, ScheduledEvent.users, 
Client.fetch_guilds, and Guild.audit_logs.

To illustrate the problem, Messageable.history counted returned
messages to tell when to stop iteration, but did so before filtering
away those past the before or after boundaries. When both 
oldest_first=False and an after boundary were provided, this led to the
history iterator continuing to retrieve messages older than the after
boundary, which would then all be filtered away, continuing until the
message limit or the beginning of the entire channel was reached. 

A similar situation would also occur with oldest_first=True and a
before boundary provided.

This commit changes the logic in these methods to count items after
filtering, so they stop requesting more as soon as the in-bounds items
are exhausted.
2022-11-27 01:43:24 -05:00
7b595fb052 Fix docstring for create_invite 2022-09-26 02:14:31 -04:00
ce06beeb6c Fix permissions-based docstrings to be more consistent 2022-09-17 14:07:39 -04:00
6981eb69c4 Normalize type formatting in TypeError
Normalize most mixed usages of `__class__`, `__class__!r`, 
`__class__.__name__!r` to the standard form of 
`__class__.__name__`
2022-09-12 15:25:55 -04:00
ab265dcb7c Add support for newest ForumChannel changes
This adds the following:

- Forum tag support
- Default reaction support
- Default slowmode for newly created threads
2022-08-31 11:09:56 -04:00
5fe54b3ae6 Remove __slots__ from abc protocols
Fix #8354
2022-08-19 19:10:19 -04:00
6381b5a8f4 Change abc.GuildChannel.overwrites to have Object keys if cache failed
Ultimately despite it not being the prettiest, Object keys ended up
being the sanest solution to this without destroying ergonomics.
2022-08-06 14:46:52 -04:00
d707019348 Bump Pyright to 1.1.265, fix type errors, and remove unnecessary ignores 2022-08-04 22:46:02 -04:00
52f3a3496b Update docs for abc.Messageable.pins() 2022-07-17 01:07:33 -04:00
5de9287902 Change abc.PrivateChannel to be a proper subclass
This fixes isinstance(thread, discord.abc.PrivateChannel) from
returning True
2022-07-04 05:48:02 -04:00
96e6261d61 Change default for purge oldest_first to match history 2022-06-13 04:54:08 -04:00
4c74523794 Fix versionadded docstrings in voice connect methods 2022-05-27 04:15:23 -04:00
77baa06a99 Fix bug in permission resolution when dealing with timed out members
This would lead to timed out members having the read_messages
permission set to True instead of False
2022-05-23 11:56:05 -04:00
04f5fcf741 Fix Connectable.connect typing having bad inference if cls is missing 2022-05-16 15:34:51 -04:00
300fb0411e Replace trigger_typing with awaiting typing context manager 2022-05-02 04:36:18 -04:00
fedfe5bec2 Add PartialChannel to list of implementing classes for Messageable 2022-05-01 13:05:07 -04:00
89eb86ecdc Add return type for __init__ 2022-04-25 02:00:27 -04:00
69b12b97c0 Sync abc.User protocol with more shared methods
This isn't *all* of them but it's a sizeable portion
2022-04-23 03:00:46 -04:00
ab33551553 Fix type hints on GuildChannel.set_permissions 2022-04-22 04:50:10 -04:00
89b9f1616c Add self_deaf and self_mute params to voice connect methods 2022-04-14 19:06:22 -04:00
1e4908b403 Add ForumChannel to abc.GuildChannel docstring 2022-04-12 04:55:56 -04:00
348764583d Add jump_url property to channels 2022-04-12 00:23:15 -04:00