17c6b070d0af — Eric S. Raymond 5 years ago
pylint cleanup.
3 files changed, 6 insertions(+), 6 deletions(-)

M Makefile
M control
M sst.py
M Makefile +1 -1
@@ 34,7 34,7 @@ check: #pylint
 COMMON_PYLINT = --rcfile=/dev/null --reports=n \
 	--msg-template="{path}:{line}: [{msg_id}({symbol}), {obj}] {msg}" \
 	--dummy-variables-rgx='^_'
-PYLINTOPTS = $(COMMON_PYLINT) --disable=C0103,C0111,C0113,C1001,C0301,C0302,C0321,C0325,C0326,C0410,C1801,E1120,R0101,R0902,R0903,R0911,R0912,R0914,R0915,R0916,R1705,R1706,R1710,W0110,W0123,W0141,W0312,W0603,W0611
+PYLINTOPTS = $(COMMON_PYLINT) --disable=C0103,C0111,C0113,C1001,C0301,C0302,C0321,C0325,C0326,C0410,C1801,E1120,R0101,R0902,R0903,R0911,R0912,R0914,R0915,R0916,R1705,R1706,R1710,W0110,W0123,W0141,W0232,W0312,W0603,W0611
 pylint:
 	@pylint --output-format=parseable $(PYLINTOPTS) sst.py
 

          
M control +1 -1
@@ 47,4 47,4 @@ XBS-Logo: trek.png
 
 XBS-VC-Tag-Template: %(version)s
 
-XBS-Validate: make check
+XBS-Validate: make pylint check

          
M sst.py +4 -4
@@ 44,7 44,7 @@ def _(st):
 
 class randomizer:
     # LCG PRNG parameters tested against
-    # Knuth vol. 2. by the authors of ADVENT 
+    # Knuth vol. 2. by the authors of ADVENT
     LCG_A = 1093
     LCG_C = 221587
     LCG_M = 1048576

          
@@ 53,7 53,7 @@ class randomizer:
     def random():
         old_x = game.lcg_x
         game.lcg_x = (randomizer.LCG_A * game.lcg_x + randomizer.LCG_C) % randomizer.LCG_M
-        return old_x / randomizer.LCG_M;
+        return old_x / randomizer.LCG_M
 
     @staticmethod
     def withprob(p):

          
@@ 196,8 196,8 @@ class Coord:
         return self.roundtogrid() % QUADSIZE
     def scatter(self):
         s = Coord()
-        s.i = self.i + rnd.range(-1, 2)
-        s.j = self.j + rnd.range(-1, 2)
+        s.i = self.i + rnd.integer(-1, 2)
+        s.j = self.j + rnd.integer(-1, 2)
         return s
     def __str__(self):
         if self.i is None or self.j is None: