GSoC/GCI Archive
Google Summer of Code 2013 Python Software Foundation

Twisted: Deferred Cancellation

by kai for Python Software Foundation

Deferreds are Twisted's abstraction for an eventual result of a task. They provide a cancellation API to add a hook for cancelling the task. However, many Twisted APIs that return Deferreds don't use this cancellation API which means they don't provide cancellation support. This project would add cancellation support to as many APIs as possible (though I will focus on SMTP, POP3, IMAP4, DNS, HTTP related APIs), starting with easy cases and moving on to more difficult ones.