Skip to content

Conversation

@max-wittig
Copy link
Member

This PR enables python-gitlab to wait if the GitLab rate-limit is hit.
It waits as long as GitLab specifies via the Retry-After header

GitLab lacks documentation about this feature, but rate-limits can be set in the Admin UI (see screenshot)
and via the settings API.
image

{
 "throttle_authenticated_api_enabled": false,
 "throttle_authenticated_api_requests_per_period": 2,
 "throttle_authenticated_api_period_in_seconds": 10,
}

It can be disabled using the obey_rate_limit=False parameter

@gpocentek
Copy link
Contributor

Hi @max-wittig

Thanks for this PR, it looks good and provides a very nice feature!

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants