-
-
Notifications
You must be signed in to change notification settings - Fork 465
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: ✨ Allow for functools.partial
and functions returning an awaitable as autocomplete
#2669
base: master
Are you sure you want to change the base?
feat: ✨ Allow for functools.partial
and functions returning an awaitable as autocomplete
#2669
Conversation
functools.partials
and such as autocompletefunctools.partials
and such as autocomplete
@DefiDebauchery Would you mind testing this pr with your usecase and |
Yes, this did work on my side, thank you! While I also like the solution offered in #2668 (comment), I do think partials make sense in many contexts, and it would be great to have support for those who need something quick. |
3382447
to
142215d
Compare
142215d
to
53036a4
Compare
functools.partials
and such as autocompletefunctools.partials
functions returning an awaitable as autocomplete
functools.partials
functions returning an awaitable as autocompletefunctools.partial
functions returning an awaitable as autocomplete
functools.partial
functions returning an awaitable as autocompletefunctools.partial
and functions returning an awaitable as autocomplete
Oh shoot checks failing... This is why we should be using |
b46e70e
to
c2b4011
Compare
9c80445
to
6ec28e1
Compare
efeb190
to
1dddf13
Compare
- Added the ability to use functions with any number of optional arguments, and | ||
functions returning an awaitable as `Option.autocomplete` | ||
([#2669](https://github.com/Pycord-Development/pycord/pull/2669)). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Added the ability to use functions with any number of optional arguments, and | |
functions returning an awaitable as `Option.autocomplete` | |
([#2669](https://github.com/Pycord-Development/pycord/pull/2669)). | |
- Added the ability to use functions with any number of optional arguments, and | |
functions returning an awaitable as `Option.autocomplete`. | |
([#2669](https://github.com/Pycord-Development/pycord/pull/2669)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary
Allows usage of functions with any number of optional parameters as autocomplete. This allows by extent the usage of partials and similar as autocomplete.
Fixes #2668
Information
examples, ...).
Checklist
type: ignore
comments were used, a comment is also left explaining why.