From b2aaa47f00da98e1ffec76dd67e2c940463b8457 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= Date: Tue, 22 Jul 2014 17:15:16 +0200 Subject: [PATCH] gently skip None as author intid --- themis/importexport/sync.py | 1 + 1 file changed, 1 insertion(+) diff --git a/themis/importexport/sync.py b/themis/importexport/sync.py index 46135b2..03be64d 100644 --- a/themis/importexport/sync.py +++ b/themis/importexport/sync.py @@ -383,6 +383,7 @@ class SyncFromThemis(UtilityView): authors_intids = [self.get_author_intid(x) for x in authors_v] if None in authors_intids: log.warn('unknown error in doc %s' % object.id) + authors_intids = [x for x in authors_intids if x is not None] object.authors = self.create_relation_value_list_if_needed( object.authors, authors_intids) object.author_is_government = False