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

Rate limit improvements #68

Merged
merged 2 commits into from Jan 22, 2023

Conversation

inducer
Copy link

@inducer inducer commented Dec 14, 2022

Summary of changes

Two changes here, happy to split if you would prefer.

  • First, with my Discourse instance (v2.8.13 on nginx, in case it makes a difference), I encountered rate-limited responses that did not have a Content-Type header. The first commit makes it so that the code takes these in stride.
  • The second commit includes information from the Discourse-Rate-Limit-Error-Code, which makes it easier to debug which limit is encountered. Also, logging happens before waiting, to provide feedback on what is happening.

Checklist

  • Changes represent a discrete update (-ish)
  • Commit messages are meaningful and descriptive
  • Changeset does not include any extraneous changes unrelated to the discrete change

@bennylope bennylope merged commit 227924f into pydiscourse:master Jan 22, 2023
@bennylope
Copy link
Collaborator

Thank you and sorry this wasn't merged earlier!

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.

None yet

2 participants