diff --git a/swh/scrubber/db.py b/swh/scrubber/db.py index 1f55b897f986b7d5c9ecae9b00638899423bee5a..8bf2ea0a63b18447820a3571838b96b44710d02e 100644 --- a/swh/scrubber/db.py +++ b/swh/scrubber/db.py @@ -993,7 +993,7 @@ class ScrubberDb(BaseDb): def fixed_object_iter(self) -> Iterator[FixedObject]: with self.transaction() as cur: cur.execute("SELECT id, object, method, recovery_date FROM fixed_object") - for (id, object_, method, recovery_date) in cur: + for id, object_, method, recovery_date in cur: yield FixedObject( id=CoreSWHID.from_string(id), object_=object_, diff --git a/swh/scrubber/journal_checker.py b/swh/scrubber/journal_checker.py index 1ce441cd156422e8f27c52fdda123061d22d4c0d..eabd4a6f0ab5570533f738ffd156043015aae412 100644 --- a/swh/scrubber/journal_checker.py +++ b/swh/scrubber/journal_checker.py @@ -108,7 +108,7 @@ class JournalChecker: self.journal_client.process(self.process_kafka_messages) def process_kafka_messages(self, all_messages: Dict[str, List[bytes]]): - for (object_type, messages) in all_messages.items(): + for object_type, messages in all_messages.items(): logger.debug("Processing %s %s", len(messages), object_type) cls = getattr(model, object_type.capitalize()) for message in messages: diff --git a/swh/scrubber/origin_locator.py b/swh/scrubber/origin_locator.py index bbee1c6057a932b45a2857c44b25d0fbf2ad9694..46bea32e42182573d015f055e2724672cc355e23 100644 --- a/swh/scrubber/origin_locator.py +++ b/swh/scrubber/origin_locator.py @@ -41,7 +41,7 @@ def get_origins( for origin_swhid_group in grouper(origin_swhids, 10): origin_swhid_group = list(origin_swhid_group) - for (origin, origin_swhid) in zip( + for origin, origin_swhid in zip( storage.origin_get_by_sha1( [origin_swhid.object_id for origin_swhid in origin_swhid_group] ), diff --git a/swh/scrubber/storage_checker.py b/swh/scrubber/storage_checker.py index e52da6f69556ce5952314bb2a2257f93a9849ce3..4e9203d6ecfcd6a724bdfde8f3085360a2ced5ab 100644 --- a/swh/scrubber/storage_checker.py +++ b/swh/scrubber/storage_checker.py @@ -217,7 +217,7 @@ class StorageChecker: ) directory_ids = page.results objects = [] - for (dir_id, item) in zip( + for dir_id, item in zip( directory_ids, directory_get_many_with_possibly_duplicated_entries( self.storage, directory_ids