session_cookie['session']['Path'] = '/'
headers = []
headers.extend(('set-cookie', morsel.OutputString()) for morsel in
    list(session_cookie.values()))
start_response('200 OK', headers)
Set a cookie and retrieve it with Python and WSGI