Skip to content

Instantly share code, notes, and snippets.

View mendelgusmao's full-sized avatar
😅
what's up?

Mendelson Gusmão mendelgusmao

😅
what's up?
View GitHub Profile
@mendelgusmao
mendelgusmao / redis_sessions.py
Created July 6, 2012 22:30 — forked from junkafarian/redis_sessions.py
Redis session management using a dictionary-like API for session objects
import redis
from zope.interface import Interface, implements
try: #pragma NO COVERAGE
import simplejson as json
except ImportError: #pragma NO COVERAGE
import json
class RedisSession(dict):
""" Provides a lazy interface for presenting data stored in a redis DB as a