Repository navigation
Conversation
|
Thanks for opening this pull request! This pull request can be checked-out with: git fetch origin pull/3448/head:pr-3448
git checkout pr-3448This pull request can be installed with: pip install git+https://github.com/Pycord-Development/pycord@refs/pull/3448/head |
Contributor
Author
|
@Paillat-dev I've done 2 files so far and I want your opinion on it. The re-sorting of the keys was done according to the official API docs as that makes stuff faster to find, and when I'm already looking at all types, I figured I might as well do that tedious work too. I also need some info on whether there's any rules on how the classes are split up (see app info in particular) or whether these should be unified into a single object if they are not explicitly separate on the API docs |
This branch has not been deployed
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
I've noticed the TypedDicts for the
.typesand.raw_modelsfolders were partly incomplete, partly wrong, and wholly a mess. So before work on correcting typing across the lib can start, this has to be corrected first, as without a correct base of what the API returns, it's all in vain.The main goals are:
total=False(using onlyRequired[...]for required keys) andtotal=True(aka not passing it) and marking non-required keys viaNotRequired[...]. I've opted for the latter approach across the lib, as it's immediately obvious what is and isn't optional, and optional keys should stand out more.Out of scope: Fixing any type errors that result from these changes in any other files, because this is partly the base for all future typing work. These changes should by all means not have any runtime effects, although I will of course do some testing.
Information
examples, ...).
Checklist
type: ignorecomments were used, a comment is also left explaining why.