Commit c7d1abb7 authored by Eric S. Raymond's avatar Eric S. Raymond
Browse files

pylint cleanup.

parent e78a3c31
......@@ -44,7 +44,7 @@ src-$(VERS).tar.gz: $(SOURCES) src.1
COMMON_PYLINT = --rcfile=/dev/null --reports=n \
--msg-template="{path}:{line}: [{msg_id}({symbol}), {obj}] {msg}" \
--dummy-variables-rgx='^_'
PYLINTOPTS = "C0103,C0123,C0301,C0302,C0325,C0326,C0330,C0410,C0413,C1001,C0111,R0101,R0902,R0903,R0904,R0201,R0912,R0913,R0914,R0915,R1705,R1723,R1724,W0110,W0141,W0142,W0143,W0232,W0311,W0312,W0603,W0511,W0613,E0401,E1101,E1103"
PYLINTOPTS = "C0103,C0123,C0301,C0302,C0325,C0326,C0330,C0410,C0413,C1001,C0111,E1120,R0101,R0902,R0903,R0904,R0201,R0912,R0913,R0914,R0915,R1705,R1723,R1724,W0110,W0141,W0142,W0143,W0232,W0311,W0312,W0603,W0511,W0613,E0401,E1101,E1103"
pylint:
@pylint $(COMMON_PYLINT) --disable=$(PYLINTOPTS) src
......
......@@ -247,6 +247,7 @@ class popen_or_die:
except (OSError, IOError) as oe:
croak("execution of %s%s failed: %s" \
% (self.command, self.legend, oe))
return None # Pacify pylint
def __exit__(self, extype, value, traceback_unused):
if extype:
if debug > 0:
......@@ -377,7 +378,8 @@ class HistoryEntry:
return t, offset
except (TypeError, ValueError):
croak("garbled date %s" % date)
def __str__(self):
return None # Pacify pylint
def __str_o_(self):
return "<%s = %s>" % (self.revno, self.native)
def registered(workfile):
......@@ -536,6 +538,7 @@ class History:
croak("{0} has no revisions".format(self.name))
else:
croak("{0} has no revno {1}".format(self.name, revno))
return None # Pacify pylint
def revno_to_native(self, revno):
"Map a revno to a native ID"
return self.by_revno(revno).native
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment