mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-13 21:53:49 +01:00
Fix comments. v0.99.2 -> v0.99.3
This commit is contained in:
parent
551ea11559
commit
c69df5d5d3
2 changed files with 6 additions and 6 deletions
|
@ -198,7 +198,7 @@ class MatrixFederationHttpClient(object):
|
||||||
):
|
):
|
||||||
"""Wrapper for _send_request which can optionally retry the request
|
"""Wrapper for _send_request which can optionally retry the request
|
||||||
upon receiving a combination of a 400 HTTP response code and a
|
upon receiving a combination of a 400 HTTP response code and a
|
||||||
'M_UNRECOGNIZED' errcode. This is a workaround for Synapse <=v0.99.2
|
'M_UNRECOGNIZED' errcode. This is a workaround for Synapse <= v0.99.3
|
||||||
due to #3622.
|
due to #3622.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
|
@ -237,7 +237,7 @@ class MatrixFederationHttpClient(object):
|
||||||
|
|
||||||
# Retry with a trailing slash if we received a 400 with
|
# Retry with a trailing slash if we received a 400 with
|
||||||
# 'M_UNRECOGNIZED' which some endpoints can return when omitting a
|
# 'M_UNRECOGNIZED' which some endpoints can return when omitting a
|
||||||
# trailing slash on Synapse <= v0.99.2.
|
# trailing slash on Synapse <= v0.99.3.
|
||||||
# Enable backoff if initially disabled
|
# Enable backoff if initially disabled
|
||||||
send_request_args["backoff_on_404"] = backoff_on_404
|
send_request_args["backoff_on_404"] = backoff_on_404
|
||||||
|
|
||||||
|
@ -560,7 +560,7 @@ class MatrixFederationHttpClient(object):
|
||||||
requests).
|
requests).
|
||||||
try_trailing_slash_on_400 (bool): True if on a 400 M_UNRECOGNIZED
|
try_trailing_slash_on_400 (bool): True if on a 400 M_UNRECOGNIZED
|
||||||
response we should try appending a trailing slash to the end
|
response we should try appending a trailing slash to the end
|
||||||
of the request. Workaround for #3622 in Synapse <=v0.99.2. This
|
of the request. Workaround for #3622 in Synapse <= v0.99.3. This
|
||||||
will be attempted before backing off if backing off has been
|
will be attempted before backing off if backing off has been
|
||||||
enabled.
|
enabled.
|
||||||
|
|
||||||
|
@ -593,7 +593,7 @@ class MatrixFederationHttpClient(object):
|
||||||
"timeout": timeout,
|
"timeout": timeout,
|
||||||
"ignore_backoff": ignore_backoff,
|
"ignore_backoff": ignore_backoff,
|
||||||
# Do not backoff on the initial request if we're trying again with
|
# Do not backoff on the initial request if we're trying again with
|
||||||
# trailing slashes Otherwise we may end up waiting to contact a
|
# trailing slashes. Otherwise we may end up waiting to contact a
|
||||||
# server that is actually up
|
# server that is actually up
|
||||||
"backoff_on_404": False if try_trailing_slash_on_400 else backoff_on_404,
|
"backoff_on_404": False if try_trailing_slash_on_400 else backoff_on_404,
|
||||||
}
|
}
|
||||||
|
@ -681,7 +681,7 @@ class MatrixFederationHttpClient(object):
|
||||||
and try the request anyway.
|
and try the request anyway.
|
||||||
try_trailing_slash_on_400 (bool): True if on a 400 M_UNRECOGNIZED
|
try_trailing_slash_on_400 (bool): True if on a 400 M_UNRECOGNIZED
|
||||||
response we should try appending a trailing slash to the end of
|
response we should try appending a trailing slash to the end of
|
||||||
the request. Workaround for #3622 in Synapse <=v0.99.2.
|
the request. Workaround for #3622 in Synapse <= v0.99.3.
|
||||||
Returns:
|
Returns:
|
||||||
Deferred[dict|list]: Succeeds when we get a 2xx HTTP response. The
|
Deferred[dict|list]: Succeeds when we get a 2xx HTTP response. The
|
||||||
result will be the decoded JSON body.
|
result will be the decoded JSON body.
|
||||||
|
|
|
@ -272,7 +272,7 @@ class FederationClientTests(HomeserverTestCase):
|
||||||
"""
|
"""
|
||||||
If a connection is made to a client but the client rejects it due to
|
If a connection is made to a client but the client rejects it due to
|
||||||
requiring a trailing slash. We need to retry the request with a
|
requiring a trailing slash. We need to retry the request with a
|
||||||
trailing slash. Workaround for Synapse <= v0.99.2, explained in #3622.
|
trailing slash. Workaround for Synapse <= v0.99.3, explained in #3622.
|
||||||
"""
|
"""
|
||||||
d = self.cl.get_json(
|
d = self.cl.get_json(
|
||||||
"testserv:8008", "foo/bar", try_trailing_slash_on_400=True,
|
"testserv:8008", "foo/bar", try_trailing_slash_on_400=True,
|
||||||
|
|
Loading…
Reference in a new issue