Menu

#35 Store session pickle error handling

closed-fixed
WebKit (45)
5
2003-01-10
2002-10-29
Oleg Noga
No

if error occurs while pickling session to a file (Session
can't be pickled), SessionFileStore leaves corrupt
session file. For all future attempts ro load this session
into memory we have KeyError, and new session is not
created.

SessionFileStore.diff patch handles exception while
pickling session and does not leave corrupt session
files. So, new session can be created with same key.

DynamicFileStore.diff patch adds a check in MovetoFile,
(was the session stored properly?), so session can be
removed from the memory store only if it was saved to a
file.
---
Patches are maked for checkout on 2002-10-29

Discussion

  • Oleg Noga

    Oleg Noga - 2002-10-29

    SessionFileStore.py patch

     
  • Oleg Noga

    Oleg Noga - 2002-10-29
     
  • Stuart Donaldson

    • assigned_to: nobody --> stuartd
     
  • Stuart Donaldson

    • status: open --> closed-fixed
     
  • Stuart Donaldson

    Logged In: YES
    user_id=326269

    Commited a fix for this bug which was not a direct match to
    the patches submitted.

    When the pickling exception occurs, now we call
    application.handleException() and that takes care of
    displaying, as logging, and emailing depending on
    configuration. The session file is not saved and gets lost
    as a result. The fix involved getting the handleException()
    in and running as well.

     

Log in to post a comment.