#NEWLINE# @ gen . convert_yielded . register ( Deferred ) #NEWLINE# def _( d ) : #NEWLINE# #INDENT# f = Future ( ) #NEWLINE# def errback( failure ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# failure . raiseException ( ) #NEWLINE# raise Exception ( 'errback called without error' ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# f . set_exc_info ( sys . exc_info ( ) ) #NEWLINE# #UNINDENT# #UNINDENT# d . addCallbacks ( f . set_result , errback ) #NEWLINE# return d