-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch fix/argument-parsing into master (#32)
* Refresh the contributing guide * Move argument processing to its own function This should make future development easier * Allow loading the library if `magic` is missing or unavailable * Formatting * Support keyword args in Argument() * Require that *, args are strings * Skip ctx in command parsing * Log which arguments are being parsed * Fix kwargs having non-string keys Also fix kwargs log message logging args * Unskip ctx.args[0] I'm not sure why this fixed what was broken but broke it in a different way too * start at index 1 when actually parsing args * don't prematurely await parsing * Add documentation regarding different argument types * Fix str sometimes erroneously being detected as invalid in arg parsing Fixes "TypeError: Keyword-only arguments must be of type str.", caused by "WARNING - Argument got an instance of a type, not a type itself: 'str'. Inspect as if it was its rawtype, <class 'str'>" * Fix the builtin str parsing not working, again * Fix python 3.9 and 3.10 support
- Loading branch information
Showing
6 changed files
with
195 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.