Showing 9,525 of 13,510 total issues
ExpatParser
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class ExpatParser(xmlreader.IncrementalParser, xmlreader.Locator):
"""SAX driver for the pyexpat C module."""
def __init__(self, namespaceHandling=0, bufsize=2**16-20):
xmlreader.IncrementalParser.__init__(self, bufsize)
Mailbox
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class Mailbox:
"""A group of messages in a particular place."""
def __init__(self, path, factory=None, create=True):
"""Initialize a Mailbox instance."""
Distribution
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class Distribution:
"""The core of the Distutils. Most of the work hiding behind 'setup'
is really done within a Distribution instance, which farms the work out
to the Distutils commands specified on the command line.
Command
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class Command:
"""Abstract base class for defining command classes, the "worker bees"
of the Distutils. A useful analogy for command classes is to think of
them as subroutines with local variables called "options". The options
are "declared" in 'initialize_options()' and "defined" (given their
DistributionMetadata
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class DistributionMetadata:
"""Dummy class to hold the distribution meta-data: name, version,
author, and so forth.
"""
dispatcher
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class dispatcher:
debug = False
connected = False
accepting = False
Mailbox
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class Mailbox:
"""A group of messages in a particular place."""
def __init__(self, path, factory=None, create=True):
"""Initialize a Mailbox instance."""
ExpatParser
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class ExpatParser(xmlreader.IncrementalParser, xmlreader.Locator):
"""SAX driver for the pyexpat C module."""
def __init__(self, namespaceHandling=0, bufsize=2**16-20):
xmlreader.IncrementalParser.__init__(self, bufsize)
DistributionMetadata
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class DistributionMetadata:
"""Dummy class to hold the distribution meta-data: name, version,
author, and so forth.
"""
Command
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class Command:
"""Abstract base class for defining command classes, the "worker bees"
of the Distutils. A useful analogy for command classes is to think of
them as subroutines with local variables called "options". The options
are "declared" in 'initialize_options()' and "defined" (given their
Distribution
has 30 functions (exceeds 20 allowed). Consider refactoring. Open
class Distribution:
"""The core of the Distutils. Most of the work hiding behind 'setup'
is really done within a Distribution instance, which farms the work out
to the Distutils commands specified on the command line.
Class Encoder
has 30 methods (exceeds 20 allowed). Consider refactoring. Open
public class Encoder : ICoder, ISetCoderProperties, IWriteCoderProperties
{
enum EMatchFinderType
{
BT2,
File pgen.py
has 319 lines of code (exceeds 250 allowed). Consider refactoring. Open
# Copyright 2004-2005 Elemental Security, Inc. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
# Pgen imports
from . import grammar, token, tokenize
File pgen.py
has 319 lines of code (exceeds 250 allowed). Consider refactoring. Open
# Copyright 2004-2005 Elemental Security, Inc. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
# Pgen imports
from . import grammar, token, tokenize
File asdl.py
has 318 lines of code (exceeds 250 allowed). Consider refactoring. Open
"""An implementation of the Zephyr Abstract Syntax Definition Language.
See http://asdl.sourceforge.net/ and
http://www.cs.princeton.edu/research/techreps/TR-554-97
File validate.py
has 316 lines of code (exceeds 250 allowed). Consider refactoring. Open
# (c) 2005 Ian Bicking and contributors; written for Paste (http://pythonpaste.org)
# Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php
# Also licenced under the Apache License, 2.0: http://opensource.org/licenses/apache2.0.php
# Licensed to PSF under a Contributor Agreement
"""
File validate.py
has 316 lines of code (exceeds 250 allowed). Consider refactoring. Open
# (c) 2005 Ian Bicking and contributors; written for Paste (http://pythonpaste.org)
# Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php
# Also licenced under the Apache License, 2.0: http://opensource.org/licenses/apache2.0.php
# Licensed to PSF under a Contributor Agreement
"""
Function GenLibraryClasses
has a Cognitive Complexity of 25 (exceeds 5 allowed). Consider refactoring. Open
def GenLibraryClasses(self, ContainerFile):
EdkLogger.debug(2, "Generate %s ..." % TAB_LIBRARY_CLASSES)
LibraryClasses = {}
#
# Get all include files
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function _GenGuidProtocolPpis
has a Cognitive Complexity of 25 (exceeds 5 allowed). Consider refactoring. Open
def _GenGuidProtocolPpis(self, Type):
Logger.Debug(2, "Generate %s ..." % Type)
#
# Get all Guid/Protocol/Ppis data
#
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function ShowWorkspaceBuild
has a Cognitive Complexity of 25 (exceeds 5 allowed). Consider refactoring. Open
def ShowWorkspaceBuild(self):
print self.DscDatabase
print self.InfDatabase
print self.DecDatabase
print 'SupArchList', self.SupArchList
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"