No activation email & errors logged on user sign-up

Hi

I’m setting up Tutor to work with user sign-up and email notifications for the first time. I’ve been using Tutor without this for a while, but this is a new install of Tutor, following the standard process.

When I attempt to register a user account, the create an account page freezes (“Create Account” button deactivated) but never reloads. I don’t receive an activation email. The user is created, which I can verify in the django / LMS Administration, but is inactive.

Here are the Tutor logs:

nginx_1             | 172.18.0.3 - - [22/Sep/2021:18:50:27 +0000] http://learning.lightunwrapped.com "POST /api/user/v1/validation/registration HTTP/1.1" 200 75 "https://learning.lightunwrapped.com/register?next=%2F" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36" "82.71.37.223"
lms_1               | [pid: 10|app: 0|req: 79/414] 172.18.0.2 () {68 vars in 1602 bytes} [Wed Sep 22 18:50:27 2021] POST /api/user/v1/validation/registration => generated 75 bytes in 51 msecs (HTTP/1.0 200) 7 headers in 226 bytes (1 switches on core 0)
lms_1               | 2021-09-22 18:50:27,822 INFO 122 [tracking] [user None] [ip 82.71.37.223] logger.py:41 - {"name": "/api/user/v2/account/registration/", "context": {"user_id": null, "path": "/api/user/v2/account/registration/", "course_id": "", "org_id": ""}, "username": "", "session": "3ecb1c4d61aa6e8f945d071e60dcc767", "ip": "82.71.37.223", "agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36", "host": "learning.lightunwrapped.com", "referer": "https://learning.lightunwrapped.com/register?next=%2F", "accept_language": "en-US,en;q=0.9", "event": "{\"GET\": {}, \"POST\": {\"email\": [\"test-user-009@lightunwrapped.com\"], \"name\": [\"Test User 009\"], \"username\": [\"test-user-009\"], \"password\": \"********\", \"level_of_education\": [\"\"], \"gender\": [\"\"], \"year_of_birth\": [\"\"], \"mailing_address\": [\"\"], \"goals\": [\"\"], \"terms_of_service\": [\"true\"]}}", "time": "2021-09-22T18:50:27.822540+00:00", "event_type": "/api/user/v2/account/registration/", "event_source": "server", "page": null}
lms_1               | 2021-09-22 18:50:28,017 INFO 122 [audit] [user 15] [ip 82.71.37.223] models.py:2590 - Login success - user.id: 15
lms_1               | 2021-09-22 18:50:28,055 INFO 122 [tracking] [user 15] [ip 82.71.37.223] logger.py:41 - {"name": "edx.user.settings.changed", "context": {"user_id": null, "path": "/api/user/v2/account/registration/", "course_id": "", "org_id": ""}, "username": "", "session": "3ecb1c4d61aa6e8f945d071e60dcc767", "ip": "82.71.37.223", "agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36", "host": "learning.lightunwrapped.com", "referer": "https://learning.lightunwrapped.com/register?next=%2F", "accept_language": "en-US,en;q=0.9", "event": {"old": null, "new": "en-uk", "truncated": [], "setting": "pref-lang", "user_id": 15, "table": "user_api_userpreference"}, "time": "2021-09-22T18:50:28.055373+00:00", "event_type": "edx.user.settings.changed", "event_source": "server", "page": null}
lms_1               | 2021-09-22 18:50:28,064 ERROR 122 [root] [user None] [ip None] signals.py:22 - Uncaught exception from None
lms_1               | Traceback (most recent call last):
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
lms_1               |     response = get_response(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
lms_1               |     response = self.process_exception_by_middleware(e, request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
lms_1               |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1               |     return view_func(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
lms_1               |     return self.dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
lms_1               |     return view(request, *args, **kwargs)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 485, in dispatch
lms_1               |     return super().dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
lms_1               |     response = self.handle_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
lms_1               |     self.raise_uncaught_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
lms_1               |     raise exc
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
lms_1               |     response = handler(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1               |     return view_func(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1               |     return fn(request, *args, **kw)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 529, in post
lms_1               |     response, user = self._create_account(request, data)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 572, in _create_account
lms_1               |     user = create_account_with_params(request, data)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 236, in create_account_with_params
lms_1               |     compose_and_send_activation_email(user, profile, registration)
lms_1               |   File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
lms_1               |     send_activation_email.delay(str(msg))
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
lms_1               |     return json.dumps(self, cls=MessageEncoder)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
lms_1               |     return cls(
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
lms_1               |     chunks = self.iterencode(o, _one_shot=True)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
lms_1               |     return _iterencode(o, 0)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
lms_1               |     return super().default(o)   # pragma: no cover
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
lms_1               |     raise TypeError(f'Object of type {o.__class__.__name__} '
lms_1               | TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
lms_1               | 2021-09-22 18:50:28,122 ERROR 122 [django.request] [user 15] [ip 82.71.37.223] log.py:222 - Internal Server Error: /api/user/v2/account/registration/
lms_1               | Traceback (most recent call last):
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
lms_1               |     response = get_response(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
lms_1               |     response = self.process_exception_by_middleware(e, request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
lms_1               |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1               |     return view_func(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
lms_1               |     return self.dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
lms_1               |     return view(request, *args, **kwargs)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 485, in dispatch
lms_1               |     return super().dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
lms_1               |     response = self.handle_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
lms_1               |     self.raise_uncaught_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
lms_1               |     raise exc
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
lms_1               |     response = handler(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1               |     return view_func(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1               |     return fn(request, *args, **kw)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 529, in post
lms_1               |     response, user = self._create_account(request, data)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 572, in _create_account
lms_1               |     user = create_account_with_params(request, data)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 236, in create_account_with_params
lms_1               |     compose_and_send_activation_email(user, profile, registration)
lms_1               |   File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
lms_1               |     send_activation_email.delay(str(msg))
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
lms_1               |     return json.dumps(self, cls=MessageEncoder)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
lms_1               |     return cls(
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
lms_1               |     chunks = self.iterencode(o, _one_shot=True)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
lms_1               |     return _iterencode(o, 0)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
lms_1               |     return super().default(o)   # pragma: no cover
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
lms_1               |     raise TypeError(f'Object of type {o.__class__.__name__} '
lms_1               | TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
nginx_1             | 172.18.0.3 - - [22/Sep/2021:18:50:28 +0000] http://learning.lightunwrapped.com "POST /api/user/v2/account/registration/ HTTP/1.1" 500 9235 "https://learning.lightunwrapped.com/register?next=%2F" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36" "82.71.37.223"
lms_1               | [pid: 122|app: 0|req: 89/415] 172.18.0.2 () {68 vars in 1555 bytes} [Wed Sep 22 18:50:27 2021] POST /api/user/v2/account/registration/ => generated 9235 bytes in 431 msecs (HTTP/1.0 500) 8 headers in 573 bytes (1 switches on core 0)

When trying to login as the newly created user I still don’t get the activation email and the following Tutor logs:

lms_1               | 2021-09-22 19:09:03,598 INFO 10 [tracking] [user None] [ip 82.71.37.223] logger.py:41 - {"name": "/api/user/v1/account/login_session/", "context": {"user_id": null, "path": "/api/user/v1/account/login_session/", "course_id": "", "org_id": ""}, "username": "", "session": "6d309598910a039a3f17248e77775b4f", "ip": "82.71.37.223", "agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36", "host": "learning.lightunwrapped.com", "referer": "https://learning.lightunwrapped.com/login?next=%2F", "accept_language": "en-US,en;q=0.9", "event": "{\"GET\": {}, \"POST\": {\"email\": [\"test-user-009@lightunwrapped.com\"], \"password\": \"********\"}}", "time": "2021-09-22T19:09:03.598315+00:00", "event_type": "/api/user/v1/account/login_session/", "event_source": "server", "page": null}
lms_1               | 2021-09-22 19:09:03,707 WARNING 10 [audit] [user None] [ip 82.71.37.223] login.py:165 - Login failed - Account not active for user.id: 15, resending activation
lms_1               | 2021-09-22 19:09:03,719 ERROR 10 [root] [user None] [ip None] signals.py:22 - Uncaught exception from None
lms_1               | Traceback (most recent call last):
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
lms_1               |     response = get_response(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
lms_1               |     response = self.process_exception_by_middleware(e, request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
lms_1               |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/contextlib.py", line 75, in inner
lms_1               |     return func(*args, **kwds)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1               |     return view_func(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
lms_1               |     return self.dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
lms_1               |     return view(request, *args, **kwargs)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 617, in dispatch
lms_1               |     return super().dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
lms_1               |     response = self.handle_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
lms_1               |     self.raise_uncaught_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
lms_1               |     raise exc
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
lms_1               |     response = handler(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "./openedx/core/lib/api/view_utils.py", line 393, in _wrapped
lms_1               |     return func(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 142, in _wrapped_view
lms_1               |     response = view_func(request, *args, **kwargs)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 613, in post
lms_1               |     return login_user(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 142, in _wrapped_view
lms_1               |     response = view_func(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/http.py", line 40, in inner
lms_1               |     return func(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1               |     return fn(request, *args, **kw)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1               |     return fn(request, *args, **kw)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 510, in login_user
lms_1               |     _handle_failed_authentication(user, possibly_authenticated_user)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 216, in _handle_failed_authentication
lms_1               |     _log_and_raise_inactive_user_auth_error(user)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 170, in _log_and_raise_inactive_user_auth_error
lms_1               |     compose_and_send_activation_email(unauthenticated_user, profile)
lms_1               |   File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
lms_1               |     send_activation_email.delay(str(msg))
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
lms_1               |     return json.dumps(self, cls=MessageEncoder)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
lms_1               |     return cls(
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
lms_1               |     chunks = self.iterencode(o, _one_shot=True)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
lms_1               |     return _iterencode(o, 0)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
lms_1               |     return super().default(o)   # pragma: no cover
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
lms_1               |     raise TypeError(f'Object of type {o.__class__.__name__} '
lms_1               | TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
lms_1               | 2021-09-22 19:09:03,769 ERROR 10 [django.request] [user None] [ip 82.71.37.223] log.py:222 - Internal Server Error: /api/user/v1/account/login_session/
lms_1               | Traceback (most recent call last):
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
lms_1               |     response = get_response(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
lms_1               |     response = self.process_exception_by_middleware(e, request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
lms_1               |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/contextlib.py", line 75, in inner
lms_1               |     return func(*args, **kwds)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1               |     return view_func(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
lms_1               |     return self.dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
lms_1               |     return view(request, *args, **kwargs)
nginx_1             | 172.18.0.3 - - [22/Sep/2021:19:09:03 +0000] http://learning.lightunwrapped.com "POST /api/user/v1/account/login_session/ HTTP/1.1" 500 8068 "https://learning.lightunwrapped.com/login?next=%2F" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36" "82.71.37.223"
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 617, in dispatch
lms_1               |     return super().dispatch(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
lms_1               |     response = self.handle_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
lms_1               |     self.raise_uncaught_exception(exc)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
lms_1               |     raise exc
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
lms_1               |     response = handler(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "./openedx/core/lib/api/view_utils.py", line 393, in _wrapped
lms_1               |     return func(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1               |     return bound_method(*args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 142, in _wrapped_view
lms_1               |     response = view_func(request, *args, **kwargs)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 613, in post
lms_1               |     return login_user(request)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 142, in _wrapped_view
lms_1               |     response = view_func(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/http.py", line 40, in inner
lms_1               |     return func(request, *args, **kwargs)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1               |     return fn(request, *args, **kw)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1               |     return fn(request, *args, **kw)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 510, in login_user
lms_1               |     _handle_failed_authentication(user, possibly_authenticated_user)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 216, in _handle_failed_authentication
lms_1               |     _log_and_raise_inactive_user_auth_error(user)
lms_1               |   File "./openedx/core/djangoapps/user_authn/views/login.py", line 170, in _log_and_raise_inactive_user_auth_error
lms_1               |     compose_and_send_activation_email(unauthenticated_user, profile)
lms_1               |   File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
lms_1               |     send_activation_email.delay(str(msg))
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
lms_1               |     return json.dumps(self, cls=MessageEncoder)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
lms_1               |     return cls(
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
lms_1               |     chunks = self.iterencode(o, _one_shot=True)
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
lms_1               |     return _iterencode(o, 0)
lms_1               |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
lms_1               |     return super().default(o)   # pragma: no cover
lms_1               |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
lms_1               |     raise TypeError(f'Object of type {o.__class__.__name__} '
lms_1               | TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
lms_1               | [pid: 10|app: 0|req: 102/472] 172.18.0.2 () {68 vars in 1588 bytes} [Wed Sep 22 19:09:03 2021] POST /api/user/v1/account/login_session/ => generated 8068 bytes in 303 msecs (HTTP/1.0 500) 7 headers in 410 bytes (1 switches on core 0)

However, if I then request a password reset I do receive the standard password reset email. I can then reset the password as normal, am logged in, and the account is marked as active. Other password reset emails also work, so SMTP is setup and working properly.

My issue appears to be similar to this, but it doesn’t look like the cause is the same:

Are there any ideas or fixes for this?

Thank-you!

Hi @David! What tutor version are you running? Did you customize the sign up email template in any way?

Hi @regis

I’m running Tutor latest, currently v12.1.2. I haven’t customised any of the email templates (might need to look at that later, but the reset email is fine as is). The only customisation from the default was to install the indigo theme and update the logos and indigo/config.yml following the instructions there.

Hello @regis
I am also getting similar error on user registration, the CREAT ACCOUNT button greys out and the page gets stuck. (reset email is fine an i get the email)

I have pasted error log below

[pid: 6|app: 0|req: 18/68] 10.1.187.20 () {58 vars in 1419 bytes} [Tue Sep 28 05:21:51 2021] POST /api/user/v1/validation/registration => generated 63 bytes in 38 msecs (HTTP/1.0 403) 7 headers in 230 bytes (1 switches on core 0)
2021-09-28 05:21:51,830 INFO 122 [audit] [user 11] [ip XY.XY.XY.XY] models.py:2590 - Login success - user.id: 11
2021-09-28 05:21:51,994 INFO 122 [tracking] [user 11] [ip XY.XY.XY.XY] logger.py:41 - {"name": "edx.user.settings.changed", "context": {"user_id": null, "path": "/api/user/v2/account/registration/", "course_id": "", "org_id": ""}, "username": "", "session": "9fd62edf2ba9f44638a3af99a7d26132", "ip": "XY.XY.XY.XY", "agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.120 Safari/537.36", "host": "mooc.stag.tanitgh.net", "referer": "https://mooc.stag.tanitgh.net/register?next=%2F", "accept_language": "en-US,en;q=0.9,af;q=0.8", "event": {"old": null, "new": "en", "truncated": [], "setting": "pref-lang", "user_id": 11, "table": "user_api_userpreference"}, "time": "2021-09-28T05:21:51.993705+00:00", "event_type": "edx.user.settings.changed", "event_source": "server", "page": null}
2021-09-28 05:21:52,068 ERROR 122 [root] [user None] [ip None] signals.py:22 - Uncaught exception from None
Traceback (most recent call last):
  File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
    response = get_response(request)
  File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
    response = self.process_exception_by_middleware(e, request)
  File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
    return view_func(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
    return self.dispatch(request, *args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
    return view(request, *args, **kwargs)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 485, in dispatch
    return super().dispatch(request, *args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
    response = self.handle_exception(exc)
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
    self.raise_uncaught_exception(exc)
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
    raise exc
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
    response = handler(request, *args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
    return view_func(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
    return fn(request, *args, **kw)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 529, in post
    response, user = self._create_account(request, data)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 572, in _create_account
    user = create_account_with_params(request, data)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 236, in create_account_with_params
    compose_and_send_activation_email(user, profile, registration)
  File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
    send_activation_email.delay(str(msg))
  File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
    return json.dumps(self, cls=MessageEncoder)
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
    return cls(
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
    return super().default(o)   # pragma: no cover
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
2021-09-28 05:21:52,174 ERROR 122 [django.request] [user 11] [ip XY.XY.XY.XY] log.py:222 - Internal Server Error: /api/user/v2/account/registration/
Traceback (most recent call last):
  File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
    response = get_response(request)
  File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
    response = self.process_exception_by_middleware(e, request)
  File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
    return view_func(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
    return self.dispatch(request, *args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
    return view(request, *args, **kwargs)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 485, in dispatch
    return super().dispatch(request, *args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
    response = self.handle_exception(exc)
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
    self.raise_uncaught_exception(exc)
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
    raise exc
  File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
    response = handler(request, *args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
    return view_func(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
    return bound_method(*args, **kwargs)
  File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
    return fn(request, *args, **kw)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 529, in post
    response, user = self._create_account(request, data)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 572, in _create_account
    user = create_account_with_params(request, data)
  File "./openedx/core/djangoapps/user_authn/views/register.py", line 236, in create_account_with_params
    compose_and_send_activation_email(user, profile, registration)
  File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
    send_activation_email.delay(str(msg))
  File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
    return json.dumps(self, cls=MessageEncoder)
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
    return cls(
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
    return super().default(o)   # pragma: no cover
  File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
[pid: 122|app: 0|req: 16/69] 10.1.187.20 () {58 vars in 1372 bytes} [Tue Sep 28 05:21:51 2021] POST /api/user/v2/account/registration/ => generated 12581 bytes in 858 msecs (HTTP/1.0 500) 8 headers in 571 bytes (1 switches on core 0)

@regis I’m experiencing the same issue with a fresh install with the latest release. may need a quick fix.

lms_1            | 2021-09-28 16:03:53,515 INFO 114 [audit] [user 4] [ip 172.18.0.1] models.py:2590 - Login success - user.id: 4
lms_1            | 2021-09-28 16:03:53,557 INFO 114 [tracking] [user 4] [ip 172.18.0.1] logger.py:41 - {"name": "edx.user.settings.changed", "context": {"user_id": null, "path": "/api/user/v2/account/registration/", "course_id": "", "org_id": ""}, "username": "", "session": "7bf4f84c3b9d77fa953d23880585a2f8", "ip": "172.18.0.1", "agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.63 Safari/537.36", "host": "local.overhang.io", "referer": "http://local.overhang.io/register?next=%2F", "accept_language": "en-GB,en-US;q=0.9,en;q=0.8", "event": {"old": null, "new": "en", "truncated": [], "setting": "pref-lang", "user_id": 4, "table": "user_api_userpreference"}, "time": "2021-09-28T16:03:53.556761+00:00", "event_type": "edx.user.settings.changed", "event_source": "server", "page": null}
lms_1            | 2021-09-28 16:03:53,567 ERROR 114 [root] [user None] [ip None] signals.py:22 - Uncaught exception from None
lms_1            | Traceback (most recent call last):
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
lms_1            |     response = get_response(request)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
lms_1            |     response = self.process_exception_by_middleware(e, request)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
lms_1            |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1            |     return view_func(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
lms_1            |     return self.dispatch(request, *args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
lms_1            |     return view(request, *args, **kwargs)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 485, in dispatch
lms_1            |     return super().dispatch(request, *args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
lms_1            |     response = self.handle_exception(exc)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
lms_1            |     self.raise_uncaught_exception(exc)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
lms_1            |     raise exc
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
lms_1            |     response = handler(request, *args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1            |     return view_func(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1            |     return fn(request, *args, **kw)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 529, in post
lms_1            |     response, user = self._create_account(request, data)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 572, in _create_account
lms_1            |     user = create_account_with_params(request, data)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 236, in create_account_with_params
lms_1            |     compose_and_send_activation_email(user, profile, registration)
lms_1            |   File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
lms_1            |     send_activation_email.delay(str(msg))
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
lms_1            |     return json.dumps(self, cls=MessageEncoder)
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
lms_1            |     return cls(
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
lms_1            |     chunks = self.iterencode(o, _one_shot=True)
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
lms_1            |     return _iterencode(o, 0)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
lms_1            |     return super().default(o)   # pragma: no cover
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
lms_1            |     raise TypeError(f'Object of type {o.__class__.__name__} '
lms_1            | TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable
lms_1            | 2021-09-28 16:03:53,664 ERROR 114 [django.request] [user 4] [ip 172.18.0.1] log.py:222 - Internal Server Error: /api/user/v2/account/registration/
lms_1            | Traceback (most recent call last):
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 34, in inner
lms_1            |     response = get_response(request)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 115, in _get_response
lms_1            |     response = self.process_exception_by_middleware(e, request)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/core/handlers/base.py", line 113, in _get_response
lms_1            |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1            |     return view_func(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/generic/base.py", line 71, in view
lms_1            |     return self.dispatch(request, *args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
lms_1            |     return view(request, *args, **kwargs)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 485, in dispatch
lms_1            |     return super().dispatch(request, *args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 509, in dispatch
lms_1            |     response = self.handle_exception(exc)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 469, in handle_exception
lms_1            |     self.raise_uncaught_exception(exc)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
lms_1            |     raise exc
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/rest_framework/views.py", line 506, in dispatch
lms_1            |     response = handler(request, *args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
lms_1            |     return view_func(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/django/utils/decorators.py", line 45, in _wrapper
lms_1            |     return bound_method(*args, **kwargs)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/ratelimit/decorators.py", line 24, in _wrapped
lms_1            |     return fn(request, *args, **kw)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 529, in post
lms_1            |     response, user = self._create_account(request, data)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 572, in _create_account
lms_1            |     user = create_account_with_params(request, data)
lms_1            |   File "./openedx/core/djangoapps/user_authn/views/register.py", line 236, in create_account_with_params
lms_1            |     compose_and_send_activation_email(user, profile, registration)
lms_1            |   File "/openedx/edx-platform/common/djangoapps/student/views/management.py", line 214, in compose_and_send_activation_email
lms_1            |     send_activation_email.delay(str(msg))
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 29, in __str__
lms_1            |     return json.dumps(self, cls=MessageEncoder)
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/__init__.py", line 234, in dumps
lms_1            |     return cls(
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 199, in encode
lms_1            |     chunks = self.iterencode(o, _one_shot=True)
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 257, in iterencode
lms_1            |     return _iterencode(o, 0)
lms_1            |   File "/openedx/venv/lib/python3.8/site-packages/edx_ace/serialization.py", line 119, in default
lms_1            |     return super().default(o)   # pragma: no cover
lms_1            |   File "/opt/pyenv/versions/3.8.6/lib/python3.8/json/encoder.py", line 179, in default
lms_1            |     raise TypeError(f'Object of type {o.__class__.__name__} '
lms_1            | TypeError: Object of type LazyStaticAbsoluteUrl is not JSON serializable

Frontend:

POST http://local.overhang.io/api/user/v2/account/registration/ 500 (Internal Server Error)
send @ lms-base-vendor.188b06b0a06d.js:4
ajax @ lms-base-vendor.188b06b0a06d.js:4
sync @ logistration_factory.e32d5e4d472c.js?raw:1
save @ lms-base-vendor.188b06b0a06d.js:10
submitForm @ logistration_factory.e32d5e4d472c.js?raw:1
submitForm @ logistration_factory.e32d5e4d472c.js?raw:1
dispatch @ lms-base-vendor.188b06b0a06d.js:2
elemData.handle @ lms-base-vendor.188b06b0a06d.js:2
VM105:10 Uncaught SyntaxError: Unexpected token < in JSON at position 9
    at JSON.parse (<anonymous>)
    at child.saveError (logistration_factory.e32d5e4d472c.js?raw:1)
    at triggerEvents (lms-base-vendor.188b06b0a06d.js:10)
    at triggerApi (lms-base-vendor.188b06b0a06d.js:10)
    at eventsApi (lms-base-vendor.188b06b0a06d.js:10)
    at child.Events.trigger (lms-base-vendor.188b06b0a06d.js:10)
    at Object.error (logistration_factory.e32d5e4d472c.js?raw:1)
    at fire (lms-base-vendor.188b06b0a06d.js:2)
    at Object.fireWith [as rejectWith] (lms-base-vendor.188b06b0a06d.js:2)
    at done (lms-base-vendor.188b06b0a06d.js:4)
saveError @ logistration_factory.e32d5e4d472c.js?raw:1
triggerEvents @ lms-base-vendor.188b06b0a06d.js:10
triggerApi @ lms-base-vendor.188b06b0a06d.js:10
eventsApi @ lms-base-vendor.188b06b0a06d.js:10
Events.trigger @ lms-base-vendor.188b06b0a06d.js:10
error @ logistration_factory.e32d5e4d472c.js?raw:1
fire @ lms-base-vendor.188b06b0a06d.js:2
fireWith @ lms-base-vendor.188b06b0a06d.js:2
done @ lms-base-vendor.188b06b0a06d.js:4
(anonymous) @ lms-base-vendor.188b06b0a06d.js:4
load (async)
send @ lms-base-vendor.188b06b0a06d.js:4
ajax @ lms-base-vendor.188b06b0a06d.js:4
sync @ logistration_factory.e32d5e4d472c.js?raw:1
save @ lms-base-vendor.188b06b0a06d.js:10
submitForm @ logistration_factory.e32d5e4d472c.js?raw:1
submitForm @ logistration_factory.e32d5e4d472c.js?raw:1
dispatch @ lms-base-vendor.188b06b0a06d.js:2
elemData.handle @ lms-base-vendor.188b06b0a06d.js:2

I managed to reproduce the issue and am looking at this right now. Thanks for the heads up.

1 Like

Here is the fix: fix: 500 error during user registration by regisb · Pull Request #501 · overhangio/tutor · GitHub Can someone please try it out? If not I’ll merge the PR today and create a new release anyway.

The fix was reviewed and merged, v12.1.3 will be released in a few minutes.

Sorry I wasn’t able to do anything with the change earlier today.

I’ve upgraded to v12.1.3 and this works fine now. Thanks.

@regis As you said i upgraded to the latest version. But it still didn’t resolve my problem.

Did you run tutor local quickstart after upgrading? (you should have) At the very least, you should run:

tutor config save
tutor local restart lms

If it still does not work, please paste here the output of:

which tutor
tutor --version

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.