Add typing and modernize docs for resource subclasses.
Review Request #14245 — Created Nov. 13, 2024 and submitted
This change modernizes the existing resource subclasses, fixing up
typing and documentation. This also adds any missing item or list
resource subclasses to match the ones we have.
- Ran unit tests.
- Used the RBTools API for various tests.
Summary | ID |
---|---|
31d7b46a1d08bd1b09b460e988f3d5f9c0406dfa |
Description | From | Last Updated | ||
---|---|---|---|---|
multiple spaces after keyword Column: 36 Error code: E271 |
![]() |
|||
missing whitespace around operator Column: 6 Error code: E225 |
![]() |
|||
Swap these (ordering issue). |
|
|||
While cleaning up these, it might be a good time to move to keyword-only arguments and use housekeeping to deprecate … |
|
|||
These should probably say dict of .... |
|
|||
Another good candidate, if it's worth moving to kwonly args in this change. |
|
|||
These are in a different order from the argument list. |
|
|||
Another candidate. |
|
|||
There are no open issues |
- Commits:
-
Summary ID 6d95d09c215e540e170f60d6b693ce4bc5996e5b 3529401517bee7583803a6045f5bb861a38a85b0 - Diff:
-
Revision 2 (+1094 -276)
Checks run (2 succeeded)
-
Very nice.
A few suggestions and couple example places for those suggestions, if you want to make that part of this change, but otherwise this pretty much looks good to go to me.
-
-
While cleaning up these, it might be a good time to move to keyword-only arguments and use housekeeping to deprecate the positionals. Doesn't have to be in this change (I don't want to expand the scope), so feel free to drop.
-
-
-
-
-
Just an observation and room for possible future improvement. We type the return of
HttpRequest
, but document a resource type. The latter is what the caller should ultimately expect but the former is the reality of the function. Not sure what to do there. ShouldHttpRequest
someday be generic with the resulting payload type? Something we can mull over.
- Commits:
-
Summary ID 3529401517bee7583803a6045f5bb861a38a85b0 31d7b46a1d08bd1b09b460e988f3d5f9c0406dfa - Diff:
-
Revision 3 (+1100 -272)