fixed SkipList.finalize's arguments causing pylint warnings
[p2pool.git] / p2pool / util / skiplist.py
index 154edeb..e9e36c2 100644 (file)
@@ -1,4 +1,4 @@
-from p2pool.util import math
+from p2pool.util import math, memoize
 
 class SkipList(object):
     def __init__(self, p=0.5):
@@ -9,6 +9,7 @@ class SkipList(object):
     def forget_item(self, item):
         self.skips.pop(item, None)
     
+    @memoize.memoize_with_backing(memoize.LRUDict(5))
     def __call__(self, start, *args):
         updates = {}
         pos = start
@@ -54,5 +55,5 @@ class SkipList(object):
             for x in updates:
                 updates[x] = updates[x][0], self.combine_deltas(updates[x][1], delta) if updates[x][1] is not None else delta
     
-    def finalize(self, sol):
+    def finalize(self, sol, args):
         return sol