Useful utilities for Twisted development.
This is a very early stage project. It works for our needs. We haven't verified it works beyond that. Issue reports and patches are very much appreciated!
git clone https://github.com/Greplin/greplin-twisted-utils.git cd greplin-twisted-utils python setup.py install
Context management - allows setting context variables that persist across asynchronous events. This is highly experimental!
Deferred events - pub/sub model for events.
Lazy map - map that lazily computes its values, possibly requiring asynchronous computation.
Retry logic for deferred requests that may fail transiently
Time - simple utilities for deferred objects that fire after a specified time
Deferred wrapper - allows for success / failure to be handled at the very end of the callback chain.
- DNS cache - avoid repeatedly resolving the same DNS names
- Mock implementation of greplin.defer.time