Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save mjrusso/340787 to your computer and use it in GitHub Desktop.

Select an option

Save mjrusso/340787 to your computer and use it in GitHub Desktop.
# pyres/failure/redis.py
@classmethod
def all(cls, resq, start=0, count=1):
items = resq.redis.lrange('resque:failed', start, count) or []
ret_list = []
for i in items:
failure = ResQ.decode(i)
failure['redis_value'] = base64.b64encode(i)
ret_list.append(failure)
return ret_list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment