better handling of exceptions when session expired
[myslice.git] / manifold / manifoldapi.py
index 664bb32..180807b 100644 (file)
@@ -113,6 +113,8 @@ def _execute_query(request, query, manifold_api_session_auth):
     print "-"*80
     result = manifold_api.forward(query.to_dict())
     if result['code'] == 2:
+        # XXX only if we know it is the issue
+        del request.session['manifold']
         raise Exception, 'Error running query: %r' % result
     
     if result['code'] == 1: