about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authortoonn <toonn@toonn.io>2022-05-26 15:22:44 +0200
committertoonn <toonn@toonn.io>2022-05-26 15:22:44 +0200
commit4a1fc7eb92f11145e945d69e6dd6a0730b5c17c4 (patch)
treeba9a24a385fdec73b76a9b657f6bec79cdc27996
parent9252d69ede0b2a086fb7359706d7ef58b41e6561 (diff)
downloadranger-4a1fc7eb92f11145e945d69e6dd6a0730b5c17c4.tar.gz
accumulator: Make get_list an abstract method
Implementations need the `self` parameter and PyLint complains when the
number of arguments changes. Since it's never used without
reimplementation, `@abstractmethod` is appropriate.
-rw-r--r--ranger/ext/accumulator.py6
1 files changed, 4 insertions, 2 deletions
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 []