From 73ef85bc5db590c22689e11be20737a3dd88168f Mon Sep 17 00:00:00 2001 From: Niall Sheridan Date: Wed, 28 Dec 2016 21:18:36 +0000 Subject: Update dependencies --- vendor/github.com/google/go-github/github/doc.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'vendor/github.com/google/go-github/github/doc.go') diff --git a/vendor/github.com/google/go-github/github/doc.go b/vendor/github.com/google/go-github/github/doc.go index 2b61068..659dd82 100644 --- a/vendor/github.com/google/go-github/github/doc.go +++ b/vendor/github.com/google/go-github/github/doc.go @@ -86,6 +86,21 @@ To detect an API rate limit error, you can check if its type is *github.RateLimi Learn more about GitHub rate limiting at http://developer.github.com/v3/#rate-limiting. +Accepted Status + +Some endpoints may return a 202 Accepted status code, meaning that the +information required is not yet ready and was scheduled to be gathered on +the GitHub side. Methods known to behave like this are documented specifying +this behavior. + +To detect this condition of error, you can check if its type is +*github.AcceptedError: + + stats, _, err := client.Repositories.ListContributorsStats(org, repo) + if _, ok := err.(*github.AcceptedError); ok { + log.Println("scheduled on GitHub side") + } + Conditional Requests The GitHub API has good support for conditional requests which will help -- cgit v1.2.3