diff options
author | Bryan Newbold <bnewbold@robocracy.org> | 2018-09-14 15:02:52 -0700 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2018-09-14 15:06:47 -0700 |
commit | 61caceebcc5cd04b28d9859b27ac314bb2a59bbb (patch) | |
tree | ee70241ade0fb769e33b0312873826d243740282 /python/fatcat/crossref_importer.py | |
parent | ac0b49ee3e04d98ad5b6dd8c2360a71d7ecce1a3 (diff) | |
download | fatcat-61caceebcc5cd04b28d9859b27ac314bb2a59bbb.tar.gz fatcat-61caceebcc5cd04b28d9859b27ac314bb2a59bbb.zip |
add insert counting to importers
Diffstat (limited to 'python/fatcat/crossref_importer.py')
-rw-r--r-- | python/fatcat/crossref_importer.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/python/fatcat/crossref_importer.py b/python/fatcat/crossref_importer.py index a2e14ed1..2154c8c0 100644 --- a/python/fatcat/crossref_importer.py +++ b/python/fatcat/crossref_importer.py @@ -160,6 +160,7 @@ class FatcatCrossrefImporter(FatcatImporter): re.container_id = container.ident self._issnl_id_map[ce.issnl] = container.ident self.api.create_release(re, editgroup=editgroup) + self.insert_count = self.insert_count + 1 def create_batch(self, batch, editgroup=None): """Current work/release pairing disallows batch creation of releases. @@ -178,3 +179,4 @@ class FatcatCrossrefImporter(FatcatImporter): self._issnl_id_map[ce.issnl] = container.ident release_batch.append(re) self.api.create_release_batch(release_batch, autoaccept="true", editgroup=editgroup) + self.insert_count = self.insert_count + len(release_batch) |