Skip to content

Was there a particular reason decorators were favored over signature parsing? #322

Discussion options

You must be logged in to vote

Decorators weren't a design choice, they just relay fluent methods on the relevant object to give you a different method of call chaining; the design choice is that this library uses the fluent builder pattern.

ctx.options mostly exists for checks and hooks (not necessarily command execution as it's less feature rich than pass_as_kwargs), it is built before any argument conversion or verification is done and therefore will not contain defaults or the converted value but rather contains SlashOptions which has the raw value and helper methods which asserts the option type for you and get the "resolved" object.

Signature parsing has been a maybe-TODO for years by now https://github.com/Faste…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@GoogolGenius
Comment options

@GoogolGenius
Comment options

Answer selected by GoogolGenius
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants