Fix pylint issues
authorAntoine Busque <abusque@efficios.com>
Mon, 9 Nov 2015 00:25:47 +0000 (19:25 -0500)
committerAntoine Busque <abusque@efficios.com>
Mon, 9 Nov 2015 00:28:14 +0000 (19:28 -0500)
Signed-off-by: Antoine Busque <abusque@efficios.com>
lttnganalyses/cli/io.py
lttnganalyses/cli/irq.py
lttnganalyses/cli/mi.py
lttnganalyses/cli/sched.py
lttnganalyses/core/cputop.py

index ef3281ac096c27f9840bf69a0a5f3bfdfe01bb91..a41853406be9f0bfe0a35760c4fefdda9bf22610 100644 (file)
@@ -840,7 +840,6 @@ class IoAnalysisCommand(Command):
         if not result_table.rows:
             return
 
-        values = []
         graph = Pyasciigraph()
         graph_data = []
 
@@ -1082,7 +1081,6 @@ class IoAnalysisCommand(Command):
 
         result_table = self._mi_create_result_table(
             self._MI_TABLE_CLASS_PART_LATENCY_STATS, begin, end)
-        append_fn = self._append_latency_stats_row_from_requests
 
         for disk in self._analysis.disks.values():
             if disk.rq_count:
index 6be8feac9e63d90678ba73db34b709d932595150..8582432330ce58b48e7d96e56d981fabab60a702 100644 (file)
@@ -310,8 +310,6 @@ class IrqAnalysisCommand(Command):
 
             counts[index] += 1
 
-        graph_data = []
-
         for index, count in enumerate(counts):
             lower_bound = index * step + min_duration
             upper_bound = (index + 1) * step + min_duration
index 64aca9793f31e8ee6bcb439df0f3fc960bb7f146..ddbbceb07ea476ba715008646784d1cd845d7152 100644 (file)
@@ -60,8 +60,11 @@ class ColumnDescription:
 
 
 class TableClass:
-    def __init__(self, name, title, column_descriptions_tuples=[],
+    def __init__(self, name, title, column_descriptions_tuples=None,
                  inherit=None):
+        if column_descriptions_tuples is None:
+            column_descriptions_tuples = []
+
         self._inherit = inherit
         self._name = name
         self._title = title
@@ -133,10 +136,6 @@ class ResultTable:
     def subtitle(self):
         return self._subtitle
 
-    @property
-    def title(self):
-        return self._table_class.title
-
     def append_row(self, **kwargs):
         row = self._column_named_tuple(**kwargs)
         self._rows.append(row)
index f8a3c95a531ba86cc403a49924fb81bda0694080..3364589c20532bbad9c87ec04a4204c9e356fc50 100644 (file)
@@ -24,7 +24,6 @@
 from .command import Command
 from ..core import sched
 from ..linuxautomaton import common
-from ..ascii_graph import Pyasciigraph
 from . import mi
 import math
 import operator
@@ -349,7 +348,7 @@ class SchedAnalysisCommand(Command):
             self._mi_create_result_table(self._MI_TABLE_CLASS_PER_PRIO_STATS,
                                          begin_ns, end_ns)
 
-        prio_sched_lists, prio_stats = self._get_prio_sched_lists_stats()
+        _, prio_stats = self._get_prio_sched_lists_stats()
 
         for prio in sorted(prio_stats):
             stats = prio_stats[prio]
@@ -445,8 +444,8 @@ class SchedAnalysisCommand(Command):
             buckets.append(i * step)
             counts.append(0)
 
-        for sched in sched_list:
-            duration = sched.latency / 1000
+        for sched_event in sched_list:
+            duration = sched_event.latency / 1000
             index = int((duration - min_duration) / step)
 
             if index >= resolution:
index a6edd48fb412db860a4a7ed53e5e4cacc47b8b33..1bd5c7cf8841b128b780af074fd5f73b1e2c4177 100644 (file)
@@ -87,7 +87,6 @@ class Cputop(Analysis):
         timestamp = kwargs['timestamp']
         cpu_id = kwargs['cpu_id']
         wakee_proc = kwargs['wakee_proc']
-        next_tid = kwargs['next_tid']
 
         if not self._filter_cpu(cpu_id):
             return
This page took 0.028348 seconds and 5 git commands to generate.