Skip to content

Minor enhancements to rate limiting information#186

Merged
jacquev6 merged 1 commit into
PyGithub:developfrom
edjackson:enhanceRateLimit
Aug 19, 2013
Merged

Minor enhancements to rate limiting information#186
jacquev6 merged 1 commit into
PyGithub:developfrom
edjackson:enhanceRateLimit

Conversation

@edjackson
Copy link
Copy Markdown
Contributor

If rate limiting information hasn't been retrieved already, it will be checked (against the /rate_limit endpoint) rather than just assuming 5000 requests remaining of 5000.

Add an additional attribute rate_limiting_resettime to reflect github's new X-RateLimit-Reset header. This integer value is a unix timestamp. (In order to avoid breaking anyone's code, I added a new attribute rather than adding a third value to the rate_limiting tuple.)

RateLimiting unit test updated accordingly. I'm pretty sure I did the right thing in re-recording the replay data, but please double-check this.

If rate limiting information hasn't been retrieved already, it will be checked
rather than just assuming 5000 requests remaining of 5000.

Add an additional attribute `rate_limiting_resettime` to reflect github's new
X-RateLimit-Reset header. This integer value is a unix timestamp.

RateLimiting unit test updated accordingly.
@jacquev6
Copy link
Copy Markdown
Member

Thank you for you contribution! I'm back from holidays, I will integrate your work in the next release of PyGithub.

@ghost ghost assigned jacquev6 Aug 15, 2013
@jacquev6 jacquev6 merged commit 211e463 into PyGithub:develop Aug 19, 2013
jacquev6 added a commit that referenced this pull request Aug 21, 2013
@edjackson edjackson added the v1 label Mar 2, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants