diff --git a/gnocchiclient/benchmark.py b/gnocchiclient/benchmark.py index 9764f5f..bb4701e 100644 --- a/gnocchiclient/benchmark.py +++ b/gnocchiclient/benchmark.py @@ -99,8 +99,8 @@ def _log_progress(self, verb): LOG.info( "%d/%d, " "total: %.2f seconds, " - "rate: %.2f %s/second" - % (done, self.times, runtime, rate, verb)) + "rate: %.2f %s/second", + done, self.times, runtime, rate, verb) def wait_job(self, verb, futures): while self.statistics.executed != self.times: @@ -117,7 +117,7 @@ def wait_job(self, verb, futures): results.append(result) latencies.append(latency) except Exception as e: - LOG.error("Error with %s metric: %s" % (verb, e)) + LOG.error("Error with %s metric: %s", (verb, e)) latencies = sorted(latencies) return results, runtime, { 'client workers': self._max_workers, @@ -320,8 +320,8 @@ def take_action(self, parsed_args): break else: LOG.info( - "Remaining measures to be processed: %d" - % remaining) + "Remaining measures to be processed: %d", + remaining) time.sleep(1) return self.dict2columns(stats) diff --git a/tox.ini b/tox.ini index cfe6304..413fd1e 100644 --- a/tox.ini +++ b/tox.ini @@ -48,6 +48,7 @@ commands = show-source = True ignore = D100,D101,D102,D103,D104,D105,D107,A002,A003 exclude=.git,.tox,dist,doc,*egg,build +enable-extensions=G application-import-names = gnocchiclient [pytest]