Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add --no-token flag to git-pr #270

Closed
wants to merge 3 commits into from
Closed

Conversation

edvbld
Copy link
Member

@edvbld edvbld commented Nov 26, 2019

Hi all,

please review this pull request that adds a --no-token flag to git-pr. This is useful for those merely wanting to try out the read-only operations of git-pr (such as git pr list or git pr show) or for those that do not want to create a personal access token (PAT). The downside for not using a token for read-only operations is that GitHub quite aggressively rate limits the number of REST API HTTP operations (seems like 60 REST API HTTP operations per minute at the moment).

Thanks,
Erik

Testing

  • Manual testing of various git-pr subcommands

Progress

  • Change must not contain extraneous whitespace
  • Change must be properly reviewed

Approvers

@bridgekeeper
Copy link

bridgekeeper bot commented Nov 26, 2019

👋 Welcome back ehelin! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request (refresh this page to view it).

@mlbridge
Copy link

mlbridge bot commented Nov 26, 2019

Webrevs

@edvbld
Copy link
Member Author

edvbld commented Nov 26, 2019

Robin please note that this patch also makes some changes to GitHubHost.java, GitHubRepository.java and how those classes handle the installation token (I also cleaned up an old test that didn't require a token).

Copy link
Member

@rwestberg rwestberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Perhaps a typo, but the anonymous rate limit is actually 60 requests per hour (not minute) so even worse. :)

@openjdk openjdk bot removed the rfr label Nov 26, 2019
@openjdk
Copy link

openjdk bot commented Nov 26, 2019

@edvbld This change can now be integrated. The commit message will be:

Add --no-token flag to git-pr

Reviewed-by: rwestberg
  • If you would like to add a summary, use the /summary command.
  • To list additional contributors, use the /contributor command.
  • To integrate this PR with the above commit message, type /integrate in a new comment.

@openjdk openjdk bot added the ready label Nov 26, 2019
@openjdk openjdk bot removed the outdated label Nov 26, 2019
@edvbld
Copy link
Member Author

edvbld commented Nov 26, 2019

/integrate

@openjdk openjdk bot closed this Nov 26, 2019
@openjdk openjdk bot added integrated and removed ready labels Nov 26, 2019
@openjdk
Copy link

openjdk bot commented Nov 26, 2019

@edvbld
Pushed as commit 5c3f278.

@mlbridge
Copy link

mlbridge bot commented Nov 26, 2019

Mailing list message from Erik Helin on skara-dev:

Changeset: 5c3f278
Author: Erik Helin
Date: 2019-11-26 12:32:27 +0000
URL: https://git.openjdk.java.net/skara/commit/5c3f278d

Add --no-token flag to git-pr

Reviewed-by: rwestberg

! cli/src/main/java/org/openjdk/skara/cli/GitPr.java
! forge/src/main/java/org/openjdk/skara/forge/github/GitHubHost.java
! forge/src/main/java/org/openjdk/skara/forge/github/GitHubRepository.java
! forge/src/test/java/org/openjdk/skara/forge/github/GitHubHostTests.java

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants