Project

General

Profile

Bug #10286

''NoneType' object has no attribute 'has_form_token'' sur session perdue

Added by Frédéric Péters almost 5 years ago. Updated over 4 years ago.

Status:
Fermé
Priority:
Normal
Assignee:
-
Target version:
Start date:
14 Mar 2016
Due date:
% Done:

0%

Estimated time:
Patch proposed:
Yes
Planning:

Description

Exception:
  type = '<type 'exceptions.AttributeError'>', value = ''NoneType' object has no attribute 'has_form_token''

Stack trace (most recent call first):
  File "/usr/lib/python2.7/dist-packages/wcs/forms/root.py", line 884, in autosave
   882         # reload session to make sure _ajax_form_token is still valid
   883         session = get_session_manager().get(get_session().id)
>  884         if not session.has_form_token(get_request().form.get('_ajax_form_token')):
   885             return result_error('obsolete ajax form token (late check)')
   886

  locals:
     result_error = <function result_error at 0x7fc489358758>
     form = <wcs.qommon.form.Form object at 0x46b0d90>
     magictoken = 'adab052d4bf27383'
     session = None
     form_data = {'future_tracking_code': 'GCDPBRWX', '37': None, '1': 'B', '2': None, '5': None, '4': None, '7': None, '6': None}
     data = {'37': None, '1': 'B', '2': None, '5': None, '4': None, '7': None, '6': None}
     self = <wcs.backoffice.submission.FormFillPage object at 0x474c810>
     page_no = 0

Files

Associated revisions

Revision 1e2d3450 (diff)
Added by Frédéric Péters almost 5 years ago

misc: check for lost session in autosave (#10286)

History

#1

Updated by Frédéric Péters almost 5 years ago

#2

Updated by Thomas Noël almost 5 years ago

on met le même message d'erreur «obsolete ajax form token (late check)» ou plutôt «cannot get ajax form token (no session)» ?

#3

Updated by Thomas Noël almost 5 years ago

  • Target version set to v1.42
#4

Updated by Frédéric Péters almost 5 years ago

+            return result_error('cannot get ajax form token (lost session)')

ok?

#5

Updated by Thomas Noël almost 5 years ago

Bien sûr, go.

#6

Updated by Frédéric Péters almost 5 years ago

  • Status changed from En cours to Résolu (à déployer)
commit 1e2d34506ff4f0b18d3ee9d808e5b321f98af725
Author: Frédéric Péters <fpeters@entrouvert.com>
Date:   Tue Apr 19 18:19:01 2016 +0200

    misc: check for lost session in autosave (#10286)
#7

Updated by Frédéric Péters over 4 years ago

  • Status changed from Résolu (à déployer) to Fermé

Also available in: Atom PDF