My favorites | Sign in
Project Home Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 89: file based sessions are not stored in windows enviornment
1 person starred this issue and may be notified of changes. Back to list
Status:  Invalid
Owner:  ----
Closed:  Apr 2010


 
Reported by Pradnya....@gmail.com, Mar 24, 2010
I am using windows XP and Python with django
1. changed the SESSION_ENGINE to 'django.contrib.sessions.backends.file'
2. SESSION_FILE_PATH = 'd:/tmp'
3. In view.py defined 2 methods/views as follows
 
def show_login(request):
	request.session['test'] = "Hello World"
	return render_to_response('login.html')
	

def form_submit(request):
	return render_to_response('home.html', {'result' : request.session['test']})	

On click of test button click from login.html it will call form_submit view. 

It loads the login.html and also creates session file in d:/tmp but while
reading the session it throws following error on the browser 

KeyError at /form_submit
stack trace
#  C:\Python26\lib\site-packages\django\core\handlers\base.py  in get_response
response = callback(request, *callback_args, **callback_kwargs)

# D:\PythonSample\mysite\..\mysite\portal\views.py in form_submit
return render_to_response('home.html', {'result' : request.session['test']}) 

# C:\Python26\lib\site-packages\django\contrib\sessions\backends\base.py in
__getitem__
return self._session[key] 


I am using django version 1.1.1, OS Windows xp and python 2.6 

Please let me know what is wrong here or are there any other changes need
to be done for file based session. 


Apr 1, 2010
Project Member #1 rwpoul...@gmail.com
Sorry; this is not the right place to get this problem fixed. This is the issue
tracker for the django-forum project, which requires an existing working Django
installation.

To help you get Django up and running in your environment I would suggest the
django-users mailing list; http://groups.google.com/group/django-users
Status: Invalid

Powered by Google Project Hosting