Skip to content

Commit

Permalink
Update index.rst
Browse files Browse the repository at this point in the history
fixed broken link to Flask-KVSession documentation.
  • Loading branch information
miguelgrinberg committed Aug 28, 2014
1 parent a405054 commit 4bd1f2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ Flask-SocketIO attempts to make working with SocketIO event handlers easier by m
- An application context is pushed before invoking an event handler making ``current_app`` and ``g`` available to the handler.
- A request context is also pushed before invoking a handler, also making ``request`` and ``session`` available. Note that WebSocket events do not have individual requests associated with them, so the request context will be based on the request that started the WebSocket connection.
- The ``request`` context global is enhanced with a ``namespace`` member. This is the gevent-socketio namespace object, which offers direct access to the low level socket.
- The ``session`` context global behaves in a different way than in regular requests. A copy of the user session at the time the SocketIO connection is established is made available to handlers invoked in the context of that connection. Any changes made to the session inside a SocketIO handler are preserved, but only in the SocketIO context, these changes will not be seen by regular HTTP handlers. The technical reason for this limitation is that to save the user session a cookie needs to be sent to the client, and that requires HTTP request and response, which do not exist in a socket connection. When using server-side session storage SocketIO handlers can update user sessions even for HTTP routes (see the `Flask-KVsession <http://flask-kvsession.readthedocs.org/en/latest/>`_ extension).
- The ``session`` context global behaves in a different way than in regular requests. A copy of the user session at the time the SocketIO connection is established is made available to handlers invoked in the context of that connection. Any changes made to the session inside a SocketIO handler are preserved, but only in the SocketIO context, these changes will not be seen by regular HTTP handlers. The technical reason for this limitation is that to save the user session a cookie needs to be sent to the client, and that requires HTTP request and response, which do not exist in a socket connection. When using server-side session storage SocketIO handlers can update user sessions even for HTTP routes (see the `Flask-KVsession <http://pythonhosted.org/Flask-KVSession/>`_ extension).
- Before and after request hooks are not invoked for SocketIO connections.

Deployment
Expand Down

0 comments on commit 4bd1f2a

Please sign in to comment.