cannot login after automatic logout

Bug #1453754 reported by Giovanni Tirloni
22
This bug affects 5 people
Affects Status Importance Assigned to Milestone
django-openstack-auth
Invalid
Undecided
Unassigned

Bug Description

After being logged out due to inactivity, the next login attempt fails with "Something went wrong" error. This happens with any user.

First successful login:
2015-05-11 01:56:11,986 2327 INFO openstack_auth.forms Login successful for user "gtirloni".

Second unsuccessful login:
2015-05-11 10:24:30,717 2328 INFO openstack_auth.forms Login successful for user "gtirloni".
2015-05-11 10:24:30,718 2328 ERROR django.request Internal Server Error: /dashboard/auth/login/
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 132, in get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/usr/lib/python2.7/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
    return view(request, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/django/utils/decorators.py", line 110, in _wrapped_view
    response = view_func(request, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/django/views/decorators/cache.py", line 57, in _wrapped_view_func
    response = view_func(request, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/openstack_auth/views.py", line 111, in login
    **kwargs)
  File "/usr/lib/python2.7/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
    return view(request, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/django/utils/decorators.py", line 110, in _wrapped_view
    response = view_func(request, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/django/views/decorators/cache.py", line 57, in _wrapped_view_func
    response = view_func(request, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/django/contrib/auth/views.py", line 51, in login
    auth_login(request, form.get_user())
  File "/usr/lib/python2.7/site-packages/django/contrib/auth/__init__.py", line 102, in login
    if _get_user_session_key(request) != user.pk or (
  File "/usr/lib/python2.7/site-packages/django/contrib/auth/__init__.py", line 59, in _get_user_session_key
    return get_user_model()._meta.pk.to_python(request.session[SESSION_KEY])
  File "/usr/lib/python2.7/site-packages/django/db/models/fields/__init__.py", line 969, in to_python
    params={'value': value},
ValidationError: [u"'1550aa46bac146a0ac76e4801a66e065' value must be an integer."]

The workaround is to clean all cookies and start again, or possibly use an incognito window.

Revision history for this message
Matthias Runge (mrunge) wrote :

Giovanni, am I right to assume, you're using RDO?

If yes, please update python-django-openstack-auth to latest.

I assume, this is fixed with https://review.openstack.org/#/c/167981/

Revision history for this message
Giovanni Tirloni (gtirloni) wrote :

You're right! Updating that Django package worked. Thank you!

Matthias Runge (mrunge)
Changed in horizon:
status: New → In Progress
importance: Undecided → High
assignee: nobody → Matthias Runge (mrunge)
affects: horizon → django-openstack-auth
Changed in django-openstack-auth:
milestone: none → 1.3.0
Revision history for this message
Matthias Runge (mrunge) wrote :

this is a packaging issue, marking as invalid.

This is being fixed during implementation of blueprint django18

Changed in django-openstack-auth:
status: In Progress → Incomplete
assignee: Matthias Runge (mrunge) → nobody
importance: High → Undecided
Revision history for this message
jorge.veamurguia (jorge-veamurguia) wrote :

!! clear cache navigator ¡¡¡

David Lyle (david-lyle)
Changed in django-openstack-auth:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.