#NEWLINE# @ classmethod #NEWLINE# @ defer . inlineCallbacks #NEWLINE# def from_protocol( cls , proto ) : #NEWLINE# #INDENT# '\n        This creates and returns a ready-to-go TorConfig instance from the\n        given protocol, which should be an instance of\n        TorControlProtocol.\n        ' #NEWLINE# cfg = TorConfig ( control = proto ) #NEWLINE# ( yield proto . post_bootstrap ) #NEWLINE# defer . returnValue ( cfg )