Looks good to me. On Wed, 2010-04-14 at 17:20 -0400, Chris Lumens wrote: > --- > Makefile.am | 12 +-- > pychecker-false-positives | 26 ----- > pycheckrc-for-anaconda | 223 --------------------------------------------- > runpychecker.sh | 59 ------------ > 4 files changed, 2 insertions(+), 318 deletions(-) > delete mode 100644 pychecker-false-positives > delete mode 100644 pycheckrc-for-anaconda > delete mode 100755 runpychecker.sh > > diff --git a/Makefile.am b/Makefile.am > index c1c6e08..c9955c6 100644 > --- a/Makefile.am > +++ b/Makefile.am > @@ -23,8 +23,8 @@ SUBDIRS = isys po loader booty storage textw utils scripts bootdisk \ > installclasses iw command-stubs ui docs pixmaps tests fonts \ > gptsync liveinst > > -EXTRA_DIST = config.rpath COPYING pychecker-false-positives \ > - pycheckrc-for-anaconda runpychecker.sh lang-table \ > +EXTRA_DIST = config.rpath COPYING \ > + lang-table \ > anaconda.spec.in > > MAINTAINERCLEANFILES = Makefile.in config.guess config.h.in config.sub \ > @@ -58,8 +58,6 @@ xutils_la_SOURCES = xutils.c > anacondadir = $(pkgpyexecdir) > anaconda_PYTHON = *.py > > -PYCHECKERPATH = isys:textw:iw:installclasses:/usr/share/system-config-date > -PYCHECKEROPTS = -F pycheckrc-for-anaconda > ARCHIVE_TAG = $(PACKAGE_NAME)-$(PACKAGE_VERSION)-$(PACKAGE_RELEASE) > > sed_verbose = $(sed_verbose_$(V)) > @@ -97,12 +95,6 @@ src: archive > @rpmbuild -ts --nodeps $(PACKAGE_NAME)-$(PACKAGE_VERSION).tar.bz2 || exit 1 > @rm -f $(PACKAGE_NAME)-$(PACKAGE_VERSION).tar.bz2 > > -pycheck: > - PYTHONPATH=$(PYCHECKERPATH) pychecker $(PYCHECKEROPTS) *.py textw/*.py iw/*.py installclasses/*.py storage/*.py | grep -v "__init__() not called" > - > -pycheck-file: > - PYTHONPATH=.:$(PYCHECKERPATH) pychecker $(PYCHECKEROPTS) $(CHECK) | grep -v "__init__() not called" > - > api: > doxygen docs/api.cfg > > diff --git a/pychecker-false-positives b/pychecker-false-positives > deleted file mode 100644 > index 69f7cf2..0000000 > --- a/pychecker-false-positives > +++ /dev/null > @@ -1,26 +0,0 @@ > -deleted > -filter > -setattr > -^$ > -^dm.c: [0-9]*: not running as root returning empty list$ > -^Warnings...$ > -^anaconda\.py:[0-9]*: No global .* found$ > -^cmdline\.py:[0-9]*: No global \(nextWin\) found$ > -^fsset\.py:[0-9]*: Object \(bestprep\) has no attribute \(format\)$ > -^partitions.py:[0-9]*: Object \(bestprep\) has no attribute \(getPreExisting\)$ > -^partitions.py:[0-9]*: Object \(bestreq\) has no attribute \(format\)$ > -^iscsi.py:[0-9]*: Invalid arguments to \(addTarget\), got 0, expected between 1 and 7$ > -^(.*isys/isys.py|network.py):[0-9]*: Object \(.*_iface\) has no attribute \(Get.*\)$ > -^network.py:[0-9]*: Object \(.*props\) has no attribute \(Get\)$ > -^kickstart.py:[0-9]*: No global \(fileSystemTypeGet.*\) found$ > -^kickstart.py:[0-9]*: Object \(kwargs\) has no attribute \(update\)$ > -^upgrade.py:[0-9]*: No global \(getUsableLinuxFs\) found$ > -^upgrade.py:[0-9]*: No global \(SwapFileDevice\) found$ > -^upgrade.py:[0-9]*: No global \(fileSystemTypeGet\) found$ > -^upgrade.py:[0-9]*: No global \(FileSystemSetEntry\) found$ > -^upgrade.py:[0-9]*: No global \(readFstab\) found$ > -^iutil.py:[0-9]*: Object \(ppcType\) has no attribute \(items\)$ > -^livecd.py:[0-9]*: Object \(fsdict\) has no attribute \(keys\)$ > -^packages.py:[0-9]*: Object \(publicBetas\) has no attribute \(items\)$ > -^partRequests.py:[0-9]*: Format string argument count \(0\) doesn't match arguments \(1\)$ > -Note this last line must never end with a newline > \ No newline at end of file > diff --git a/pycheckrc-for-anaconda b/pycheckrc-for-anaconda > deleted file mode 100644 > index dc2c2e0..0000000 > --- a/pycheckrc-for-anaconda > +++ /dev/null > @@ -1,223 +0,0 @@ > -# > -# .pycheckrc file created by PyChecker v0.8.17 @ Wed Sep 19 12:18:52 2007 > -# > -# It should be placed in your home directory (value of $HOME). > -# If $HOME is not set, it will look in the current directory. > -# > - > -# only warn about files passed on the command line > -only = 1 > - > -# the maximum number of warnings to be displayed > -limit = 0 > - > -# list of evil C extensions that crash the interpreter > -evil = [] > - > -# unused imports > -importUsed = 1 > - > -# unused imports from __init__.py > -packageImportUsed = 1 > - > -# module imports itself > -reimportSelf = 1 > - > -# reimporting a module > -moduleImportErrors = 1 > - > -# module does import and from ... import > -mixImport = 1 > - > -# unused local variables, except tuples > -localVariablesUsed = 0 > - > -# all unused local variables, including tuples > -unusedLocalTuple = 0 > - > -# all unused class data members > -membersUsed = 0 > - > -# all unused module variables > -allVariablesUsed = 0 > - > -# unused private module variables > -privateVariableUsed = 1 > - > -# report each occurrence of global warnings > -reportAllGlobals = 0 > - > -# functions called with named arguments (like keywords) > -namedArgs = 0 > - > -# Attributes (members) must be defined in __init__() > -onlyCheckInitForMembers = 0 > - > -# Subclass.__init__() not defined > -initDefinedInSubclass = 0 > - > -# Baseclass.__init__() not called > -baseClassInitted = 1 > - > -# Subclass needs to override methods that only throw exceptions > -abstractClasses = 1 > - > -# Return None from __init__() > -returnNoneFromInit = 1 > - > -# unreachable code > -unreachableCode = 0 > - > -# a constant is used in a conditional statement > -constantConditions = 1 > - > -# 1 is used in a conditional statement (if 1: or while 1:) > -constant1 = 0 > - > -# check if iterating over a string > -stringIteration = 1 > - > -# check improper use of string.find() > -stringFind = 1 > - > -# Calling data members as functions > -callingAttribute = 0 > - > -# class attribute does not exist > -classAttrExists = 1 > - > -# First argument to methods > -methodArgName = 'self' > - > -# First argument to classmethods > -classmethodArgNames = ['cls', 'klass'] > - > -# unused method/function arguments > -argumentsUsed = 0 > - > -# unused method/function variable arguments > -varArgumentsUsed = 1 > - > -# ignore if self is unused in methods > -ignoreSelfUnused = 0 > - > -# check if overridden methods have the same signature > -checkOverridenMethods = 0 > - > -# check if __special__ methods exist and have the correct signature > -checkSpecialMethods = 1 > - > -# check if function/class/method names are reused > -redefiningFunction = 1 > - > -# check if using unary positive (+) which is usually meaningless > -unaryPositive = 1 > - > -# check if modify (call method) on a parameter that has a default value > -modifyDefaultValue = 1 > - > -# check if variables are set to different types > -inconsistentTypes = 0 > - > -# check if unpacking a non-sequence > -unpackNonSequence = 1 > - > -# check if unpacking sequence with the wrong length > -unpackLength = 1 > - > -# check if raising or catching bad exceptions > -badExceptions = 1 > - > -# check if statement appears to have no effect > -noEffect = 1 > - > -# check if using (expr % 1), it has no effect on integers and strings > -modulo1 = 1 > - > -# check if using (expr is const-literal), doesn't always work on integers and strings > -isLiteral = 1 > - > -# check consistent return values > -checkReturnValues = 1 > - > -# check if using implict and explicit return values > -checkImplicitReturns = 1 > - > -# check that attributes of objects exist > -checkObjectAttrs = 1 > - > -# various warnings about incorrect usage of __slots__ > -slots = 1 > - > -# using properties with classic classes > -classicProperties = 1 > - > -# check if __slots__ is empty > -emptySlots = 1 > - > -# check if using integer division > -intDivide = 1 > - > -# check if local variable shadows a global > -shadows = 0 > - > -# check if a variable shadows a builtin > -shadowBuiltins = 0 > - > -# check if input() is used > -usesInput = 1 > - > -# check if the exec statement is used > -usesExec = 0 > - > -# ignore warnings from files under standard library > -ignoreStandardLibrary = 0 > - > -# ignore warnings from the list of modules > -blacklist = ['Tkinter', 'wxPython', 'gtk', 'GTK', 'GDK'] > - > -# ignore global variables not used if name is one of these values > -variablesToIgnore = ['__version__', '__warningregistry__', '__all__', '__credits__', '__test__', '__author__', '__email__', '__revision__', '__id__', '__copyright__', '__license__', '__date__'] > - > -# ignore unused locals/arguments if name is one of these values > -unusedNames = ['_', 'empty', 'unused', 'dummy'] > - > -# ignore use of deprecated modules/functions > -deprecated = 1 > - > -# maximum lines in a function > -maxLines = 0 > - > -# maximum branches in a function > -maxBranches = 0 > - > -# maximum returns in a function > -maxReturns = 0 > - > -# maximum # of arguments to a function > -maxArgs = 0 > - > -# maximum # of locals in a function > -maxLocals = 0 > - > -# maximum # of identifier references (Law of Demeter) > -maxReferences = 5 > - > -# no module doc strings > -noDocModule = 0 > - > -# no class doc strings > -noDocClass = 0 > - > -# no function/method doc strings > -noDocFunc = 0 > - > -# print internal checker parse structures > -printParse = 0 > - > -# turn on debugging for checker > -debug = 0 > - > -# turn off all output except warnings > -quiet = 0 > - > diff --git a/runpychecker.sh b/runpychecker.sh > deleted file mode 100755 > index 186a551..0000000 > --- a/runpychecker.sh > +++ /dev/null > @@ -1,59 +0,0 @@ > -#!/bin/bash > - > -# This script will check anaconda for any pychecker warning using a set of > -# options minimizing false positives, in combination with filtering of any > -# warning regularexpressions listed in pychecker-false-positives. > -# > -# If any warnings our found they will be stored in pychecker-log and printed > -# to stdout and this script will exit with a status of 1, if no (non filtered) > -# warnings are found it exits with a status of 0 > - > -FALSE_POSITIVES=pychecker-false-positives > -NON_STRICT_OPTIONS="--no-deprecated --no-returnvalues --no-abstract" > - > -usage () { > - echo "usage: `basename $0` [--strict] [--help]" > - exit $1 > -} > - > -while [ $# -gt 0 ]; do > - case $1 in > - --strict) > - NON_STRICT_OPTIONS="" > - ;; > - --help) > - usage 0 > - ;; > - *) > - echo "Error unknown option: $1" > - usage 1 > - esac > - shift > -done > - > -if [ "`tail -c 1 pychecker-false-positives`" == "`echo`" ]; then > - echo "Error $FALSE_POSITIVES ends with an enter." > - echo "Error the last line of $FALSE_POSITIVES should never have an enter!" > - exit 1 > -fi > - > -export PYTHONPATH=".:.libs:isys:isys/.libs:textw:iw:installclasses:/usr/share/system-config-date" > - > -pychecker --only --limit 1000 \ > - --maxlines 500 --maxargs 20 --maxbranches 80 --maxlocals 60 --maxreturns 20 \ > - --no-callinit --no-local --no-shadow --no-shadowbuiltin \ > - --no-import --no-miximport --no-pkgimport --no-reimport \ > - --no-argsused --no-varargsused --no-override \ > - $NON_STRICT_OPTIONS \ > - anaconda anaconda *.py textw/*.py iw/*.py installclasses/*.py isys/*.py booty/*.py booty/*/*.py | \ > - egrep -v "`cat $FALSE_POSITIVES | tr '\n' '|'`" > pychecker-log > - > -if [ -s pychecker-log ]; then > - echo "Pychecker reports the following issues:" > - cat pychecker-log > - exit 1 > -fi > - > -rm pychecker-log > - > -exit 0 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list