Draft
Conversation
e774e70 to
1efce7c
Compare
…ckoff Introduced a LearningDelay class to manage API throttling dynamically. Updated the DeviantartOAuthAPI to utilize the new delay mechanism for improved handling of rate limits. Recover frame rate limiting with exponential backoff instead of linear.
Owner
|
By the way, I have plans on completely rewriting the DA module without any OAuth API usage. Soon ™️. So working on any OAuth API features or improvements is kind of pointless. At least in the long run. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Deviantart throttling right now i kind of bad and can have quite poor recovery performance.
When the user makes a request within the throttle period the period is increased in a tarpit probably with some exponential factor less than 2 as the DA API doc say you should use 2 as your exp backoff factor.
Current backoff logic does not account for this and moves the delay linearly which causes the user to be repeatedly penalized if they get a 429 for a long time until their throttling value gets huge, because the linear client delay is smaller than the tarpit so they will be penalized until some reset.
There are two proposed changes in this update: