Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Wrap register_device coroutine in an ensureDeferred #7684

Merged
merged 5 commits into from
Jun 16, 2020

Conversation

anoadragon453
Copy link
Member

@anoadragon453 anoadragon453 commented Jun 12, 2020

Fixes #7683

Broke in: #7649

We had a yield acting on a coroutine. To be fair this one is a bit difficult to notice as there's a function in the middle that just passes the coroutine along.

@anoadragon453 anoadragon453 requested a review from a team June 12, 2020 10:39
Copy link
Member

@richvdh richvdh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd quite like to see a test that hits this method, to avoid us breaking it again.

@gramakri
Copy link

The Cloudron package (which uses the LDAP integration) works again after applying this fix.

changelog.d/7684.bugfix Outdated Show resolved Hide resolved

# Should these be 0?
self.assertEqual(email["validated_at"], 0)
self.assertEqual(email["added_at"], 0)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like added_at at least shouldn't be, but this is probably out of scope for this PR.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems unrelated to these changes, yes. Maybe make a note somewhere to look back at this? (File an issue?)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@anoadragon453 anoadragon453 requested review from clokep and richvdh June 15, 2020 16:11
@anoadragon453
Copy link
Member Author

We've decided we want to release this as a fix in v1.15.1 as it was introduced in v1.15.0.

@anoadragon453 anoadragon453 changed the base branch from develop to release-v1.15.1 June 15, 2020 17:23
@anoadragon453 anoadragon453 force-pushed the anoa/register_device_async_fix branch from 9d1538d to 1263968 Compare June 15, 2020 17:25
@anoadragon453 anoadragon453 merged commit 3e6b5bb into release-v1.15.1 Jun 16, 2020
@anoadragon453 anoadragon453 deleted the anoa/register_device_async_fix branch June 16, 2020 09:14
babolivier pushed a commit that referenced this pull request Sep 1, 2021
* commit '03619324f':
  Create a ListenerConfig object (#7681)
  Fix changelog wording
  1.15.1
  Wrap register_device coroutine in an ensureDeferred (#7684)
  Ensure the body is a string before comparing push rules. (#7701)
  Ensure etag is a string for GET room_keys/version response (#7691)
  Update m.id.phone to use 'phone' instead of 'number' (#7687)
  Fix "There was no active span when trying to log." error (#7698)
  Enable 3PID add/bind/unbind endpoints on r0 routes
  Discard RDATA from already seen positions. (#7648)
  Replace iteritems/itervalues/iterkeys with native versions. (#7692)
  Fix warnings about losing log context during UI auth. (#7688)
  Fix a typo when comparing the URI & method during UI Auth. (#7689)
  Remove "user_id" from GET /presence. (#7606)
  Increase the default SAML session expirary time to 15 minutes. (#7664)
  fix typo in sample_config.yaml (#7652)
  Take out a lock before modifying _CACHES (#7663)
  Add option to enable encryption by default for new rooms (#7639)
  Clean-up the fallback login code. (#7657)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Login error with synapse 1.15.0 (TypeError: 'coroutine' object is not iterable)
4 participants