title: Python Twisted's DeferredLock
body: <p>Can someone provide an example and explain when and how to use Twisted's <a href="http://twistedmatrix.com/documents/current/api/twisted.internet.defer.DeferredLock.html">DeferredLock</a>.</p>
  
  <p>I have a DeferredQueue and I think I have a race condition I want to prevent, but I'm unsure how to combine the two.</p>