hooks/__init__.py
branchstable
changeset 7708 45be3a9debe6
parent 7648 5d5d98930247
child 7995 9a9f35ef418c
equal deleted inserted replaced
7707:936530f8d32c 7708:45be3a9debe6
    55             for source in repo.sources_by_eid.itervalues():
    55             for source in repo.sources_by_eid.itervalues():
    56                 if (not source.copy_based_source
    56                 if (not source.copy_based_source
    57                     or not repo.config.source_enabled(source)
    57                     or not repo.config.source_enabled(source)
    58                     or not source.config['synchronize']):
    58                     or not source.config['synchronize']):
    59                     continue
    59                     continue
    60                 session = repo.internal_session()
    60                 session = repo.internal_session(safe=True)
    61                 try:
    61                 try:
    62                     stats = source.pull_data(session)
    62                     stats = source.pull_data(session)
    63                     if stats.get('created'):
    63                     if stats.get('created'):
    64                         source.info('added %s entities', len(stats['created']))
    64                         source.info('added %s entities', len(stats['created']))
    65                     if stats.get('updated'):
    65                     if stats.get('updated'):