Rapptz
8953938a53
Update Pyright to v1.1.394
2 months ago
Danny
2e2f51fd5c
First pass at supporting user apps
Co-authored-by: red <[email protected] >
Co-authored-by: Vioshim <[email protected] >
12 months ago
Rapptz
e414d0fe04
[commands] Change default Bot.owner_ids to consider team roles
2 years ago
Alex Nørgaard
50078087e5
[commands] Fix variance issues in Bot.add_cog with List[Snowflake]
2 years ago
ster
95b6bd8782
Add coro tag to docstrings that were missing it
3 years ago
Ionite
6981eb69c4
Normalize type formatting in TypeError
Normalize most mixed usages of `__class__`, `__class__!r`,
`__class__.__name__!r` to the standard form of
`__class__.__name__`
3 years ago
Rapptz
54ee383585
[commands] Add warning if Intent.message_content is not enabled
3 years ago
Rapptz
2d586ae805
Add initial support for app command localisation
3 years ago
will
d0a52f4276
Fix typo and capitalizations in docs
3 years ago
Rapptz
53685b9b86
Change stderr prints to use the logging module instead
3 years ago
James Hilton-Balfe
5d1b63bfee
[docs] Add async with documentation for Client
Co-authored-by: Rapptz <[email protected] >
3 years ago
Josh
c9f777c873
Fix type annotations to adhere to latest pyright release
3 years ago
xCirno
6901907b69
[commands] Add seealso directive in functions referencing checks
3 years ago
Rapptz
ccc737eb07
[commands] Add support for with_app_command in hybrid commands
This allows the user to make a text-only command without it registering
as an application command
3 years ago
Michael H
d0667d08e3
[commands] Fix typing of check/check_any
This changes the type information of check decorators to return a
protocol representing that the decorator leaves the underlying object
unchanged while having a .predicate attribute.
resolves #7949
3 years ago
Rapptz
f4c5d37c8f
[commands] Rework Cog + Group inheritance to requite GroupCog
This is an attempt to fix the MRO issues present in the current
implementation. The previous implementation of using both Cog and
app_commands.Group in the inheritance chain caused issues with things
such as walk_commands due to it potentially shadowing the app_commands
version of the call.
In this particular case it's better to use composition instead of
inheritance to avoid these bugs entirely. Especially as more things are
added that could conflict with each other.
3 years ago
Rapptz
242d3f7ab7
[commands] Add Bot.hybrid_group and Bot.hybrid_command decorators
3 years ago
Rapptz
840eb577d4
[commands] Add initial implementation of hybrid commands
Hybrid commands allow a regular command to also double as a slash
command, assuming it meets the subset required to function.
3 years ago
Rapptz
76cc2c2272
Require passing intents to Client and its subclasses
3 years ago
Rapptz
994660faad
[commands] Fix unknown generic type in tree_cls
3 years ago
Rapptz
29668c51ae
[commands] Revert back to older help command implementation
The newer implementation did not play nicely with spawned tasks and
accessing HelpCommand.context, which was a frequent pain point when
writing paginated help commands.
3 years ago
Bryan Forbes
06c257760b
Update types to use Awaitable where possible
3 years ago
Jonah Lawrence
caac97c0d1
Allow empty iterables as a command_prefix
3 years ago
I. Ahmad
ae1979d17a
[commands] Add note for command tree in Bot's docstring
3 years ago
Josh
2d1cbacc58
[commands] Add tree_cls to Bot constructor
3 years ago
Bryan Forbes
062f4d6f87
Change some methods to use positional-only marker
Co-authored-by: Danny <[email protected] >
3 years ago
Stocker
eca4727593
[commands] Add missing and fix existing type annotations
3 years ago
jack1142
6dc314628e
Make guild and guilds args in Bot.remove_cog() keyword-only
3 years ago
Stanisław Jelnicki
47cb7d03ec
[commands] Type BotBase.help_command as Optional
3 years ago
HigherOrderLogic
3e70a4e798
Fix typo in add_cog doc
3 years ago
Stocker
5aa696ccfa
Fix typing issues and improve typing completeness across the library
Co-authored-by: Danny <[email protected] >
Co-authored-by: Josh <[email protected] >
3 years ago
Josh
a1c618215e
[commads] Change cog/extension load/unload methods to be async
3 years ago
Rapptz
0ef369c0fa
[commands] Automatically unload top level app commands in extensions
3 years ago
Rapptz
d68f2db7cb
[commands] Always respect guild IDs passed to cog adding and removal
Fixes #7657
3 years ago
Rapptz
446bfa78b0
[commands] Allow Cog and app_commands interopability
This changeset allows app commands defined inside Cog to work as
expected. Likewise, by deriving app_commands.Group and Cog you can
make the cog function as a top level command on Discord.
3 years ago
Alex Nørgaard
bfaee44b1f
[commands] Fix types for Bot.is_owner
3 years ago
Josh
147948af9b
Use typing.Self throughout library
3 years ago
Josh
39c5a4fdc3
Fix type-errors in commands extension
3 years ago
Rapptz
88b520b5ab
Reformat code using black
Segments where readability was hampered were fixed by appropriate
format skipping directives. New code should hopefully be black
compatible. The moment they remove the -S option is probably the moment
I stop using black though.
3 years ago
Josh
4dbe1af32f
Update sphinx and fix documentation issues
3 years ago
jack1142
dc19c6c7d5
Add positional-only arguments in more places
3 years ago
Willy
fa5a2188bb
Copy docs from Client.close() to Bot.close()
4 years ago
Josh
f3cb197429
[commands][types] Type hint commands-ext
4 years ago
thetimtoy
c4ee9dcafa
[commands] Return removed cog in Bot.remove_cog
The method now returns the removed cog, if it exists.
4 years ago
Rapptz
f56543df15
[commands] Remove function call indirection when checking author
4 years ago
Tari
36cf3c94b4
[commands] Remove Bot.self_bot
4 years ago
Josh
3864fb37a0
Fix various reference issues in documentation
Co-Authored-By: Riley Shaw <[email protected] >
4 years ago
Sebastian Law
4134a17a29
[commands] Raise error when a cog name is already registered
4 years ago
Rapptz
99fc950510
Use f-strings in more places that were missed.
4 years ago
pikaninja
1c553f51fb
[commands] Use has_error_handler instead in command_error
4 years ago