예제 #1
0
 def start(self):
     from logs import lg
     from userid import my_id
     from main.config import conf
     my_id.loadLocalIdentity()
     if my_id._LocalIdentity is None:
         lg.warn(
             'Loading local identity failed - need to create an identity first'
         )
         return False
     from main import events
     from contacts import identitycache
     from userid import known_servers
     from p2p import propagate
     from contacts import contactsdb
     identitycache.init()
     d = contactsdb.init()
     propagate.init()
     conf().addConfigNotifier('services/identity-propagate/known-servers',
                              self._on_known_servers_changed)
     lg.info('known ID servers are : %r' % known_servers.by_host())
     events.add_subscriber(self._on_local_identity_modified,
                           'local-identity-modified')
     events.add_subscriber(self._on_my_identity_rotated,
                           'my-identity-rotated')
     return d
예제 #2
0
 def start(self):
     from userid import my_id
     my_id.loadLocalIdentity()
     if my_id._LocalIdentity is None:
         from logs import lg
         lg.warn('Loading local identity failed - need to create an identity first')
         return False
     from contacts import identitycache
     identitycache.init()
     from contacts import contactsdb
     contactsdb.init()
     from p2p import propagate
     propagate.init()
     return True
 def start(self):
     from logs import lg
     from userid import my_id
     my_id.loadLocalIdentity()
     if my_id._LocalIdentity is None:
         lg.warn(
             'Loading local identity failed - need to create an identity first'
         )
         return False
     from contacts import identitycache
     identitycache.init()
     from contacts import contactsdb
     contactsdb.init()
     from p2p import propagate
     propagate.init()
     from userid import known_servers
     lg.info('known ID servers are : %r' % known_servers.by_host())
     return True