From fbbd7f2dc2d4a82d3da9327a7297f47103196544 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Fri, 22 Feb 2019 11:48:41 -0800 Subject: bunch of lint/whitespace cleanups --- python/fatcat_tools/workers/changelog.py | 3 +-- python/fatcat_tools/workers/worker_common.py | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'python/fatcat_tools/workers') diff --git a/python/fatcat_tools/workers/changelog.py b/python/fatcat_tools/workers/changelog.py index 636ed304..39a84f18 100644 --- a/python/fatcat_tools/workers/changelog.py +++ b/python/fatcat_tools/workers/changelog.py @@ -34,7 +34,7 @@ class ChangelogWorker(FatcatWorker): self.offset = 1 with topic.get_producer() as producer: - while True: + while True: latest = int(self.api.get_changelog(limit=1)[0].index) if latest > self.offset: print("Fetching changelogs from {} through {}".format( @@ -101,4 +101,3 @@ class EntityUpdatesWorker(FatcatWorker): timestamp=None, ) #consumer.commit_offsets() - diff --git a/python/fatcat_tools/workers/worker_common.py b/python/fatcat_tools/workers/worker_common.py index b84341c7..57fb710c 100644 --- a/python/fatcat_tools/workers/worker_common.py +++ b/python/fatcat_tools/workers/worker_common.py @@ -4,10 +4,11 @@ import sys import csv import json import itertools -import fatcat_client from itertools import islice from pykafka import KafkaClient from pykafka.common import OffsetType + +import fatcat_client from fatcat_client.rest import ApiException @@ -51,4 +52,3 @@ class FatcatWorker: self.kafka = KafkaClient(hosts=kafka_hosts, broker_version="1.0.0") self.produce_topic = produce_topic self.consume_topic = consume_topic - -- cgit v1.2.3