aboutsummaryrefslogtreecommitdiff
path: root/discord/ext
Commit message (Collapse)AuthorAgeFilesLines
* [commands] Actually expose the FlagError base errorRapptz2021-04-191-0/+1
|
* [commands] Initial support for FlagConverterRapptz2021-04-193-0/+608
| | | | | The name is currently pending and there's no command.signature hook for it yet since this requires bikeshedding.
* [commands] Add run_converters helper to call convertersRapptz2021-04-192-116/+186
|
* [commands] Add Context.current_parameterRapptz2021-04-192-0/+7
|
* [commands] Refactor evaluation functions to allow passing in localnsRapptz2021-04-181-8/+25
|
* [tasks] Move the Loop's sleep to be before exit conditionsSteve C2021-04-161-2/+2
| | | | | | | | | | | | This change makes it more so that `Loop.stop()` gracefully makes the current iteration the final one, by waiting AND THEN returning. The current implementation is closer to `cancel`, while also not. I encountered this because I was trying to run a `@tasks.loop(count=1)`, and inside it I print some text and change the interval, and in an `after_loop`, I restart the loop. Without this change, it immediately floods my console, due to not waiting before executing `after_loop`.
* [commands] Add a converter for discord.ObjectNadir Chowdhury2021-04-162-0/+43
|
* Restrict snowflake regexes to 15-20 digitsNadir Chowdhury2021-04-161-6/+6
|
* [commands] Remove HelpCommand.clean_prefix (#6736)pikaninja2021-04-151-19/+7
|
* [commands] Fix missing `re` import in ContextNadir Chowdhury2021-04-151-0/+1
|
* [commands] Add `clean_prefix` attribute to commands.ContextMrKomodoDragon2021-04-141-0/+14
|
* [commands] Fix Command.clean_params to return a regular dictRapptz2021-04-111-7/+10
|
* [commands] Strip text to remove spaces before ellipsisKreusada2021-04-111-1/+1
|
* [commands] Add support for Python 3.10 Union typingRapptz2021-04-111-1/+8
|
* [commands] Fix errors with cooldown mappingsRapptz2021-04-111-2/+7
|
* [commands] use __args__ and __origin__ where applicableJosh2021-04-112-17/+27
|
* [commands] Fix repr for GreedyJosh2021-04-101-0/+4
|
* [commands] Refactor typing evaluation to not use get_type_hintsRapptz2021-04-101-58/+103
| | | | | | | | | | | | | | | | get_type_hints had a few issues: 1. It would convert = None default parameters to Optional 2. It would not allow values as type annotations 3. It would not implicitly convert some string literals as ForwardRef In Python 3.9 `list['Foo']` does not convert into `list[ForwardRef('Foo')]` even though `typing.List` does this behaviour. In order to streamline it, evaluation had to be rewritten manually to support our usecases. This patch also flattens nested typing.Literal which was not done until Python 3.9.2.
* [commands] Remove legacy ExtensionNotFound.original attributeRapptz2021-04-101-4/+1
|
* [commands] Minimise code duplication in channel converters Nadir Chowdhury2021-04-101-117/+23
|
* [commands] Make `commands.Greedy` a `typing.Generic`James2021-04-102-23/+95
|
* [commands] Provide a dynamic cooldown system Dan Hess2021-04-102-19/+81
|
* [commands]Add typing.Literal converterSigmath Bits2021-04-102-30/+99
|
* [commands] Raise error when a cog name is already registeredSebastian Law2021-04-081-2/+22
|
* Use f-strings in more places that were missed.Rapptz2021-04-087-40/+42
|
* [commands] Use has_error_handler instead in command_errorpikaninja2021-04-071-2/+3
|
* [commands] Only replace annotation if one was givenRapptz2021-04-071-1/+3
|
* Add `__all__` to remaining modulesNadir Chowdhury2021-04-074-2/+17
|
* [commands] Use typing.get_type_hints to resolve ForwardRefsNadir Chowdhury2021-04-061-6/+25
|
* [commands] Fix classmethod converters not working.Rapptz2021-04-051-7/+4
| | | | Protocols sure are annoying.
* [commands] Revert conversion code back to how it was originallyRapptz2021-04-051-8/+7
|
* [commands] Fix AttributeError for classes missing convert attributeToxicKidz2021-04-051-1/+1
|
* [commands] Fix logic in Cog.has_error_handler()Rapptz2021-04-051-1/+1
|
* [commands] Address incorrect use of subclass (from type perspective)Michael H2021-04-051-4/+5
| | | This is a follow up from #6641
* [commands] Add more type information to public API of convertersMichael H2021-04-051-18/+18
|
* Use covariant TypeVar for protocolMichael H2021-04-051-1/+1
|
* [commands] Fix @classmethod converters Michael H2021-04-051-6/+9
|
* Use typing.Protocol instead of abc.ABCMetaJames2021-04-042-29/+34
|
* [commands] Use positional only parameter for Context.invokeRapptz2021-04-041-12/+2
|
* Modernize code to use f-stringsRapptz2021-04-0412-108/+85
| | | | | This also removes the encoding on the top, since Python 3 does it by default. It also changes some methods to use `yield from`.
* [commands] Add missing versionadded on StoreChannelConverterRapptz2021-04-031-5/+7
|
* [commands] Add StoreChannelConverterDoggieLicc2021-04-031-0/+40
|
* Implement StageChannel and related methodsNadir Chowdhury2021-04-031-0/+41
|
* [docs] copy signature from overridden and inherited methodsSebastian Law2021-03-291-2/+1
|
* [commands] Add support for stripping whitespace after the prefixRapptz2021-03-281-0/+10
| | | | This is configured with the strip_after_prefix option in `Bot.__init__`
* [commands] Remove nullability from help command implementationRapptz2021-03-281-16/+3
| | | | Fixes #5154
* Add remove_markdown helper functionEdwin2021-03-281-1/+8
|
* [commands] Only remove top level commands on cog load failureRapptz2021-03-281-1/+2
|
* [commands] allow arbitrary callables in cooldownMikey2021-03-282-5/+11
|
* [commands] fix documented type for Command.checksSebastian Law2021-03-241-1/+1
|