Making a python program wait until Twisted deferred returns a value,reactor.run()