Page MenuHomeSoftware Heritage
Paste P1217

Command-Line Input
ActivePublic

Authored by olasd on Nov 16 2021, 12:40 PM.
diff --git a/swh/journal/client.py b/swh/journal/client.py
index ff6f0ef..344f629 100644
--- a/swh/journal/client.py
+++ b/swh/journal/client.py
@@ -297,13 +297,13 @@ class JournalClient:
if message.value() is None:
# ignore message with no payload, these can be generated in tests
continue
- nb_processed += 1
object_type = message.topic().split(".")[-1]
deserialized_object = self.deserialize_message(
message, object_type=object_type
)
if deserialized_object is not None:
objects[object_type].append(deserialized_object)
+ nb_processed += 1
if objects:
worker_fn(dict(objects))