about summary refs log tree commit diff stats
path: root/ranger
diff options
context:
space:
mode:
authortoonn <toonn@toonn.io>2022-05-26 16:05:30 +0200
committertoonn <toonn@toonn.io>2022-05-26 16:05:30 +0200
commitaaf032252e428a1f0d2f3c6f742811f7f4b880c2 (patch)
tree1711f13eaa5439ee6b6042426ba1458394ce3227 /ranger
parent391f061cb0b0cfa8266c0651f2a6d948f22e01dd (diff)
parentff0d4852010bedbd19679c21f3729aeb1770f132 (diff)
downloadranger-aaf032252e428a1f0d2f3c6f742811f7f4b880c2.tar.gz
Merge branch 'pylint'
Diffstat (limited to 'ranger')
-rw-r--r--ranger/core/runner.py6
-rw-r--r--ranger/ext/accumulator.py6
-rw-r--r--ranger/gui/colorscheme.py5
3 files changed, 11 insertions, 6 deletions
diff --git a/ranger/core/runner.py b/ranger/core/runner.py
index 1d2b91f7..c5ec697b 100644
--- a/ranger/core/runner.py
+++ b/ranger/core/runner.py
@@ -235,9 +235,11 @@ class Runner(object):  # pylint: disable=too-few-public-methods
 
         if toggle_ui:
             self._activate_ui(False)
+
+        error = None
+        process = None
+
         try:
-            error = None
-            process = None
             self.fm.signal_emit('runner.execute.before',
                                 popen_kws=popen_kws, context=context)
             try:
diff --git a/ranger/ext/accumulator.py b/ranger/ext/accumulator.py
index a41db634..c34370d8 100644
--- a/ranger/ext/accumulator.py
+++ b/ranger/ext/accumulator.py
@@ -3,6 +3,8 @@
 
 from __future__ import (absolute_import, division, print_function)
 
+from abc import abstractmethod
+
 from ranger.ext.direction import Direction
 
 
@@ -90,8 +92,8 @@ class Accumulator(object):
     def sync_index(self, **kw):
         self.move_to_obj(self.pointed_obj, **kw)
 
-    @staticmethod
-    def get_list():
+    @abstractmethod
+    def get_list(self):
         """OVERRIDE THIS"""
         return []
 
diff --git a/ranger/gui/colorscheme.py b/ranger/gui/colorscheme.py
index 859773fb..22ff053f 100644
--- a/ranger/gui/colorscheme.py
+++ b/ranger/gui/colorscheme.py
@@ -27,6 +27,7 @@ set colorscheme yourschemename
 from __future__ import (absolute_import, division, print_function)
 
 import os.path
+from abc import abstractmethod
 from curses import color_pair
 from io import open
 
@@ -72,8 +73,8 @@ class ColorScheme(object):
         fg, bg, attr = self.get(*flatten(keys))
         return attr | color_pair(get_color(fg, bg))
 
-    @staticmethod
-    def use(_):
+    @abstractmethod
+    def use(self, context):
         """Use the colorscheme to determine the (fg, bg, attr) tuple.
 
         Override this method in your own colorscheme.