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

Login error with synapse 1.15.0 (TypeError: 'coroutine' object is not iterable) #7683

Closed
gramakri opened this issue Jun 11, 2020 · 6 comments · Fixed by #7684
Closed

Login error with synapse 1.15.0 (TypeError: 'coroutine' object is not iterable) #7683

gramakri opened this issue Jun 11, 2020 · 6 comments · Fixed by #7684
Assignees
Labels
z-bug (Deprecated Label)

Comments

@gramakri
Copy link

Tried to update our matrix install from 1.14.0 to 1.15.0. It crashes with the following error:

2020-06-11 21:42:52,523 - synapse.http.server - 113 - ERROR -  - Failed handle request via 'LoginRestServlet': <XForwardedForRequest at 0x7f89689119e8 method='POST' uri='/_matrix/client/r0/login' clientproto='HTTP/1.1' site=8008>
Traceback (most recent call last):
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
    result = g.send(result)
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
    result = g.send(result)
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
    result = g.send(result)
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
    result = g.send(result)
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
    result = g.send(result)
StopIteration: @girish:cloudron.fun

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/app/code/env/lib/python3.6/site-packages/synapse/http/server.py", line 81, in wrapped_request_handler
    await h(self, request)
  File "/app/code/env/lib/python3.6/site-packages/synapse/http/server.py", line 350, in _async_render
    callback_return = await callback_return
  File "/app/code/env/lib/python3.6/site-packages/synapse/rest/client/v1/login.py", line 149, in on_POST
    result = await self._do_other_login(login_submission)
  File "/app/code/env/lib/python3.6/site-packages/synapse/rest/client/v1/login.py", line 264, in _do_other_login
    identifier["user"], login_submission
  File "/app/code/env/lib/python3.6/site-packages/synapse/handlers/auth.py", line 722, in validate_login
    is_valid = await provider.check_password(qualified_user_id, password)
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1416, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/app/code/env/lib/python3.6/site-packages/twisted/python/failure.py", line 512, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/app/code/env/lib/python3.6/site-packages/ldap_auth_provider.py", line 180, in check_password
    user_id = yield self.register_user(localpart, givenName, mail)
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1416, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/app/code/env/lib/python3.6/site-packages/twisted/python/failure.py", line 512, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/app/code/env/lib/python3.6/site-packages/ldap_auth_provider.py", line 291, in register_user
    localpart=localpart, displayname=name, emails=emails,
  File "/app/code/env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
    result = g.send(result)
  File "/app/code/env/lib/python3.6/site-packages/synapse/module_api/__init__.py", line 113, in register
    _, access_token = yield self.register_device(user_id)
TypeError: 'coroutine' object is not iterable
@richvdh
Copy link
Member

richvdh commented Jun 12, 2020

I think this is a synapse bug; moving it accordingly.

@richvdh richvdh transferred this issue from matrix-org/matrix-synapse-ldap3 Jun 12, 2020
@richvdh richvdh added p1 z-bug (Deprecated Label) labels Jun 12, 2020
@anoadragon453
Copy link
Member

Looks like this broke in #7649

@gramakri
Copy link
Author

In case it's not clear (since the issue got transferred), this crash happens when using the ldap backend. If there is a patch, I am happy to test.

@clokep
Copy link
Member

clokep commented Jun 12, 2020

@gramakri #7684 seems to have a fix.

@gramakri
Copy link
Author

@clokep Can confirm the fix in #7684 works.

@clokep
Copy link
Member

clokep commented Jun 16, 2020

@gramakri Just an FYI that 1.15.1 was just released with a fix for this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
z-bug (Deprecated Label)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants