-
Notifications
You must be signed in to change notification settings - Fork 119
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
429 responses w/o retry_after_ms cause exception #193
Comments
Looking a bit more into this it seems that in the case I'm seeing the {
"errcode": "M_UNKNOWN",
"error": "{\"errcode\":\"M_LIMIT_EXCEEDED\",\"error\":\"Too Many Requests\",\"retry_after_ms\":650}"
} |
Also add workaround for matrix-org/matrix-python-sdk#193
Without doing any digging, this sounds like a synapse bug. @ulope, any If anyone starts a PR to try to address this, please don't add any blocking code |
Also add workaround for matrix-org/matrix-python-sdk#193
@non-Jedi I can't be sure (I'll have to re-run the test that triggered this when I get a chance) but IIRC it was either during login / registration or joining rooms. |
To be clear, I've merged a PR (in release v0.2.0) that works around this issue, but I'm leaving it open to track the upstream problem. |
Also add workaround for matrix-org/matrix-python-sdk#193
Also add workaround for matrix-org/matrix-python-sdk#193
Sometimes (no idea how this is triggered) synapse sends responses with a 429 status code without the
retry_after_ms
field. In those cases, the python client crashes with aKeyError
sincematrix-python-sdk/matrix_client/api.py
Line 666 in 401439f
retry_after_ms
to be available on 429 responses.A relatively simple solution would be to have our own internal exponential backoff counter that gets reset every time a request succeeds or an explicit
retry_after_ms
value is received.What do you think?
The text was updated successfully, but these errors were encountered: