Add new resources, part 5/7.

Review Request #14378 — Created March 20, 2025 and updated

Information

RBTools
master

Reviewers

This change adds the following new resource implementations:
- OAuthApplicationItemResource
- OAuthApplicationListResource
- OAuthTokenItemResource
- OAuthTokenListResource
- ServerInfoResource
- WatchedResource
- WatchedReviewGroupItemResource
- WatchedReviewGroupListResource
- WatchedReviewRequestItemResource
- WatchedReviewRequestListResource
- WebHookItemResource
- WebHookListResource

  • Ran unit tests.
  • Used the new resources from a test script and saw that everything
    worked as expected.
Summary ID
Add new resources, part 5/7.
This change adds the following new resource implementations: - OAuthApplicationItemResource - OAuthApplicationListResource - OAuthTokenItemResource - OAuthTokenListResource - ServerInfoResource - WatchedResource - WatchedReviewGroupItemResource - WatchedReviewGroupListResource - WatchedReviewRequestItemResource - WatchedReviewRequestListResource - WebHookItemResource - WebHookListResource Testing Done: - Ran unit tests. - Used the new resources from a test script and saw that everything worked as expected.
1e7da0cae6b52add5a122af1794406a87a7b0be7
Description From Last Updated

line too long (85 > 79 characters) Column: 80 Error code: E501

reviewbotreviewbot

I think this line needs more explanation. Also probably missing "the".

chipx86chipx86

Can we specify the format for this value?

chipx86chipx86

Missing period.

chipx86chipx86

We use "WebHook" elsewhere. Many of these docs use "webhook" though. We should make these consistent with the former.

chipx86chipx86

The second #: sould be removed. Also, we should :py:attr: the repositories reference.

chipx86chipx86

It'd be nice for these to look like a standard list, for maintainability and readability. For example: encoding: Literal[ 'application/json', …

chipx86chipx86

Might be more appropriate to :py:attr:client_secret instead of double backtick?

maubinmaubin

Should be WatchedReviewGroupListResource here.

maubinmaubin
There are no open issues
Checks run (1 failed, 1 succeeded)
flake8 failed.
JSHint passed.

flake8

david
chipx86
  1. 
      
  2. Show all issues

    I think this line needs more explanation. Also probably missing "the".

  3. rbtools/api/resource/oauth_token.py (Diff revision 2)
     
     
    Show all issues

    Can we specify the format for this value?

  4. rbtools/api/resource/webhook.py (Diff revision 2)
     
     
    Show all issues

    Missing period.

  5. rbtools/api/resource/webhook.py (Diff revision 2)
     
     
    Show all issues

    We use "WebHook" elsewhere. Many of these docs use "webhook" though. We should make these consistent with the former.

  6. rbtools/api/resource/webhook.py (Diff revision 2)
     
     
    Show all issues

    The second #: sould be removed.

    Also, we should :py:attr: the repositories reference.

  7. rbtools/api/resource/webhook.py (Diff revision 2)
     
     
     
    Show all issues

    It'd be nice for these to look like a standard list, for maintainability and readability. For example:

    encoding: Literal[
        'application/json',
        'application/xml',
        'application/x-www-form-urlencoded',
    ]
    
  8. 
      
david
maubin
  1. 
      
  2. Show all issues

    Might be more appropriate to :py:attr:client_secret instead of double backtick?

  3. rbtools/api/resource/watched.py (Diff revision 3)
     
     
    Show all issues

    Should be WatchedReviewGroupListResource here.

  4. 
      
david
Review request changed
Commits:
Summary ID
Add new resources, part 5/7.
This change adds the following new resource implementations: - OAuthApplicationItemResource - OAuthApplicationListResource - OAuthTokenItemResource - OAuthTokenListResource - ServerInfoResource - WatchedResource - WatchedReviewGroupItemResource - WatchedReviewGroupListResource - WatchedReviewRequestItemResource - WatchedReviewRequestListResource - WebHookItemResource - WebHookListResource Testing Done: - Ran unit tests. - Used the new resources from a test script and saw that everything worked as expected.
9a1877eb22fdac87948a316c08eafcd0d754b1c8
Add new resources, part 5/7.
This change adds the following new resource implementations: - OAuthApplicationItemResource - OAuthApplicationListResource - OAuthTokenItemResource - OAuthTokenListResource - ServerInfoResource - WatchedResource - WatchedReviewGroupItemResource - WatchedReviewGroupListResource - WatchedReviewRequestItemResource - WatchedReviewRequestListResource - WebHookItemResource - WebHookListResource Testing Done: - Ran unit tests. - Used the new resources from a test script and saw that everything worked as expected.
1e7da0cae6b52add5a122af1794406a87a7b0be7
Diff:

Revision 4 (+1700 -12)

Show changes

rbtools/api/resource/__init__.py
rbtools/api/resource/oauth_application.py
rbtools/api/resource/oauth_token.py
rbtools/api/resource/root.py
rbtools/api/resource/server_info.py
rbtools/api/resource/user.py
rbtools/api/resource/watched.py
rbtools/api/resource/watched_review_group.py
2 more

Checks run (2 succeeded)

flake8 passed.
JSHint passed.
maubin
  1. Ship It!
  2. 
      
Loading...