diff options
author | David Robertson <davidr@element.io> | 2023-02-13 11:49:20 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-13 11:49:20 +0000 |
commit | c10e13125057e506381d1be8c2ec1394eee45d62 (patch) | |
tree | 5f6099685ed506897d201ef7f9e1a318ce8db0b4 /synapse | |
parent | Bump sentry-sdk from 1.13.0 to 1.15.0 (#15065) (diff) | |
download | synapse-c10e13125057e506381d1be8c2ec1394eee45d62.tar.xz |
Apply logging from hotfixes branch to develop (#15054)
* Apply logging from hotfixes branch to develop Part of #4826. Originally added in #11882. * Changelog
Diffstat (limited to 'synapse')
-rw-r--r-- | synapse/rest/client/account.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/synapse/rest/client/account.py b/synapse/rest/client/account.py index 4373c73662..232f3a976d 100644 --- a/synapse/rest/client/account.py +++ b/synapse/rest/client/account.py @@ -415,6 +415,7 @@ class MsisdnThreepidRequestTokenRestServlet(RestServlet): request, MsisdnRequestTokenBody ) msisdn = phone_number_to_msisdn(body.country, body.phone_number) + logger.info("Request #%s to verify ownership of %s", body.send_attempt, msisdn) if not await check_3pid_allowed(self.hs, "msisdn", msisdn): raise SynapseError( @@ -444,6 +445,7 @@ class MsisdnThreepidRequestTokenRestServlet(RestServlet): await self.hs.get_clock().sleep(random.randint(1, 10) / 10) return 200, {"sid": random_string(16)} + logger.info("MSISDN %s is already in use by %s", msisdn, existing_user_id) raise SynapseError(400, "MSISDN is already in use", Codes.THREEPID_IN_USE) if not self.hs.config.registration.account_threepid_delegate_msisdn: @@ -468,6 +470,7 @@ class MsisdnThreepidRequestTokenRestServlet(RestServlet): threepid_send_requests.labels(type="msisdn", reason="add_threepid").observe( body.send_attempt ) + logger.info("MSISDN %s: got response from identity server: %s", msisdn, ret) return 200, ret |